Foreman-proxy with puppet-master fails to run

Hi list,

Can someone help me with a new puppet master installation via foreman-proxy?

It looks like the puppet master under passenger has problems accessing
files. This is the log when I run puppet agent -t on the new puppet
master:

==> /var/log/messages <==
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]:
(/File[/var/run/puppet]) Could not stat; permission denied
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not set
'directory' on ensure: File exists - /var/run/puppet
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not set
'directory' on ensure: File exists - /var/run/puppet
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Wrapped exception:
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: File exists -
/var/run/puppet
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]:
(/File[/var/run/puppet]/ensure) change from absent to directory
failed: Could not set 'directory' on ensure: File exists -
/var/run/puppet
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not
prepare for execution: Got 3 failure(s) while initializing: Could not
set 'directory' on ensure: File exists - /var/run/puppet; Could not
set 'directory' on ensure: File exists - /var/run/puppet
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Wrapped exception:
Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: File exists -
/var/run/puppet; change from absent to directory failed: Could not set
'directory' on ensure: File exists - /var/run/puppet

Is there anywhere the httpd user set for this, or there are any
groups/permissions that I need to set?

I have an older installation (with foreman installer 1.2) that works
without problems. But I can't find any differences between them

Best regards,
Cristian Falcas

I forgot to mention that all dirs/ files are own by puppet:puppet.

Also, the Passenger RackApp: /etc/puppet/rack fails to spawn (I
presume because of the above errors).

··· On Mon, Dec 9, 2013 at 2:54 PM, Cristian Falcas wrote: > Hi list, > > Can someone help me with a new puppet master installation via foreman-proxy? > > It looks like the puppet master under passenger has problems accessing > files. This is the log when I run puppet agent -t on the new puppet > master: > > ==> /var/log/messages <== > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: > (/File[/var/run/puppet]) Could not stat; permission denied > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not set > 'directory' on ensure: File exists - /var/run/puppet > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not set > 'directory' on ensure: File exists - /var/run/puppet > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Wrapped exception: > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: File exists - > /var/run/puppet > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: > (/File[/var/run/puppet]/ensure) change from absent to directory > failed: Could not set 'directory' on ensure: File exists - > /var/run/puppet > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not > prepare for execution: Got 3 failure(s) while initializing: Could not > set 'directory' on ensure: File exists - /var/run/puppet; Could not > set 'directory' on ensure: File exists - /var/run/puppet > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Wrapped exception: > Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: File exists - > /var/run/puppet; change from absent to directory failed: Could not set > 'directory' on ensure: File exists - /var/run/puppet > > > > Is there anywhere the httpd user set for this, or there are any > groups/permissions that I need to set? > > I have an older installation (with foreman installer 1.2) that works > without problems. But I can't find any differences between them > > Best regards, > Cristian Falcas

Stupid me. It was because selinux.

··· On Mon, Dec 9, 2013 at 2:58 PM, Cristian Falcas wrote: > I forgot to mention that all dirs/ files are own by puppet:puppet. > > Also, the Passenger RackApp: /etc/puppet/rack fails to spawn (I > presume because of the above errors). > > > On Mon, Dec 9, 2013 at 2:54 PM, Cristian Falcas wrote: >> Hi list, >> >> Can someone help me with a new puppet master installation via foreman-proxy? >> >> It looks like the puppet master under passenger has problems accessing >> files. This is the log when I run puppet agent -t on the new puppet >> master: >> >> ==> /var/log/messages <== >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: >> (/File[/var/run/puppet]) Could not stat; permission denied >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not set >> 'directory' on ensure: File exists - /var/run/puppet >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not set >> 'directory' on ensure: File exists - /var/run/puppet >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Wrapped exception: >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: File exists - >> /var/run/puppet >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: >> (/File[/var/run/puppet]/ensure) change from absent to directory >> failed: Could not set 'directory' on ensure: File exists - >> /var/run/puppet >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Could not >> prepare for execution: Got 3 failure(s) while initializing: Could not >> set 'directory' on ensure: File exists - /var/run/puppet; Could not >> set 'directory' on ensure: File exists - /var/run/puppet >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: Wrapped exception: >> Dec 9 07:46:49 v-is-puppetwork-01 puppet-master[27984]: File exists - >> /var/run/puppet; change from absent to directory failed: Could not set >> 'directory' on ensure: File exists - /var/run/puppet >> >> >> >> Is there anywhere the httpd user set for this, or there are any >> groups/permissions that I need to set? >> >> I have an older installation (with foreman installer 1.2) that works >> without problems. But I can't find any differences between them >> >> Best regards, >> Cristian Falcas