puppetmaster fails to start using dist puppet.conf file

1,055 views
Skip to first unread message

Matthew Pounsett

unread,
Feb 8, 2011, 5:39:28 PM2/8/11
to puppet...@googlegroups.com

I'm having an issue with the default puppet.conf distributed with puppet 2.6.4 (FreeBSD port). I've reproduced the problem with a completely fresh install on a completely fresh OS in a VM. Under these conditions, running puppetmaster with no config is fine, but simply moving the puppet.conf-dist file to puppet.conf causes the following errors on console:

Performing sanity check of puppetmaster configuration: FAILED, puppetmaster exited with status 1
Could not prepare for execution: Got 1 failure(s) while initializing: change from directory to file failed: Could not set 'file on ensure: Is a directory - /var/puppet/facts
/usr/local/etc/rc.d/puppetmaster: WARNING: failed precmd routine for puppetmaster

and the following is logged to syslog:

Feb 8 22:34:06 puppetmaster puppet-master[14713]: (/File[/var/puppet/facts]) Not removing directory; use 'force' to override
Feb 8 22:34:06 puppetmaster puppet-master[14713]: (/File[/var/puppet/facts]) Not removing directory; use 'force' to override
Feb 8 22:34:06 puppetmaster puppet-master[14713]: (/File[/var/puppet/facts]/ensure) change from directory to file failed: Could not set 'file on ensure: Is a directory - /var/puppet/facts
Feb 8 22:34:07 puppetmaster puppet-master[14719]: (/File[/var/puppet/facts]) Not removing directory; use 'force' to override
Feb 8 22:34:07 puppetmaster puppet-master[14719]: (/File[/var/puppet/facts]) Not removing directory; use 'force' to override
Feb 8 22:34:07 puppetmaster puppet-master[14719]: (/File[/var/puppet/facts]/ensure) change from directory to file failed: Could not set 'file on ensure: Is a directory - /var/puppet/facts

/var/puppet/facts is a directory, and I'm not sure why puppet would want to convert it to a file, or why it would fail to do so if it really needs it to be a file.

> ls -ld /var/puppet/ /var/puppet/facts/
drwxr-xr-x 12 puppet puppet 512 Jan 25 18:00 /var/puppet/
drwxr-xr-x 2 puppet puppet 512 Jan 25 18:00 /var/puppet/facts/

facts-related config entries in the dist puppet.conf are:

> grep fact puppet.conf | grep -v '^ *#'
factsource = puppet://puppet/facts/
factpath = /var/puppet/lib/facter:/var/puppet/facts
factdest = /var/puppet/facts/

Does anyone know what's causing this, or how to correct it? Google is showing me a couple other occurrences of this with older versions, but no solutions.


randomcontrol

unread,
Feb 16, 2011, 7:11:33 AM2/16/11
to Puppet Users
I removed the "facts" directory and puppet now starts without
problems, but it doesn't create a facts-file or -directory
automatically.

Matthew Pounsett

unread,
Feb 18, 2011, 7:26:08 PM2/18/11
to puppet...@googlegroups.com

I reached the same conclusion. I still have no idea why the complaint or even really what generated it.. in all the reading I've done I've never seen anything that describes what appears to be a default manifest that the puppet master applies to its own system. And, if it is indeed such a thing, I think it's weird that it only does it in the presence of a config file.

Also of note, after a bit of digging into the build process, I established that the default config file I referenced in my original email is actually generated by 'puppetmasterd --genconfig' so I find it even more strange that it doesn't work out of the box.

Brian Zaugg

unread,
Mar 8, 2011, 8:28:33 PM3/8/11
to puppet...@googlegroups.com

Comment out the 'factdest' setting in the [master] section of the config files
produced by the --genconfig option and it will work.

-Brian

Reply all
Reply to author
Forward
0 new messages