Bug #4382

puppetmasterd --mkusers on OS X is failing

Added by Trevor Menagh over 1 year ago. Updated 7 months ago.

Status:Closed Start date:07/27/2010
Priority:Normal Due date:
Assignee:Nigel Kersten % Done:

0%

Category:OSX
Target version:2.7.0
Affected Puppet version:2.6.0 Branch:http://github.com/puppetlabs/puppet/tree/next
Keywords:OSX, mkusers, puppetmasterd
Votes: 1

Description

Summary: On a fresh install of Puppet 2.6.0 on Mac OS X 10.6.4 the command puppetmasterd --mkusers produces errors

Steps to Reproduce:

sudo -i
curl -o facter-latest.tgz http://puppetlabs.com/downloads/facter/facter-latest.tgz
curl -o puppet-latest.tgz http://puppetlabs.com/downloads/puppet/puppet-latest.tgz
tar zxvf facter-latest.tgz
cd facter-1.5.7
/usr/bin/ruby ./conf/osx/createpackage.sh
installer -pkg facter-1.5.7.pkg -target /
cd ..
tar zxvf puppet-latest.tgz
cd puppet-2.6.0
/usr/bin/ruby ./conf/osx/createpackage.sh
installer -pkg puppet-2.6.0.pkg -target /
/usr/sbin/puppetmasterd --mkusers --verbose --debug

Expected Results:

Puppet Maser Daemon should start.

Actual Results:

Could not prepare for execution: Got 32 failure(s) while initializing: Tried to get name field for silly id 4294967294; Tried to get name field for silly id 4294967294; change from root to 4294967294 failed: Failed to set owner to '4294967294': integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; change from wheel to puppet failed: failed to chgrp /var/lib/puppet/reports to 4294967294: integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; Tried to get name field for silly id 4294967294; change from root to 4294967294 failed: Failed to set owner to '4294967294': integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; change from wheel to puppet failed: failed to chgrp /var/lib/puppet/server_data to 4294967294: integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; Tried to get name field for silly id 4294967294; change from root to 4294967294 failed: Failed to set owner to '4294967294': integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; change from wheel to puppet failed: failed to chgrp /var/lib/puppet/yaml to 4294967294: integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; change from root to 4294967294 failed: Failed to set owner to '4294967294': integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; Tried to get name field for silly id 4294967294; change from root to 4294967294 failed: Failed to set owner to '4294967294': integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; change from wheel to puppet failed: failed to chgrp /var/lib/puppet/log to 4294967294: integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; Tried to get name field for silly id 4294967294; change from root to 4294967294 failed: Failed to set owner to '4294967294': integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; change from wheel to puppet failed: failed to chgrp /var/lib/puppet/rrd to 4294967294: integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; Tried to get name field for silly id 4294967294; change from root to 4294967294 failed: Failed to set owner to '4294967294': integer 4294967294 too big to convert to `int'; Tried to get name field for silly id 4294967294; change from wheel to puppet failed: failed to chgrp /var/lib/puppet/bucket to 4294967294: integer 4294967294 too big to convert to `int'

Regression:

This can be fixed by using the root user to start up puppet:

puppet.conf:
[main]
  user = 0
  group = 0

and starting the puppet master without —mkusers

Notes:

This took me a long time to figure out. It would be nice to have the puppet master work on OS X out of the box using the instructions provided.

History

Updated by Trevor Menagh over 1 year ago

Steps to Reproduce (properly formatted):

sudo -i
curl -o facter-latest.tgz http://puppetlabs.com/downloads/facter/facter-latest.tgz
curl -o puppet-latest.tgz http://puppetlabs.com/downloads/puppet/puppet-latest.tgz
tar zxvf facter-latest.tgz cd facter-1.5.7
/usr/bin/ruby ./conf/osx/createpackage.sh
installer -pkg facter-1.5.7.pkg -target /
cd ..
tar zxvf puppet-latest.tgz
cd puppet-2.6.0
/usr/bin/ruby ./conf/osx/createpackage.sh
installer -pkg puppet-2.6.0.pkg -target /
/usr/sbin/puppetmasterd —mkusers —verbose —debug

Updated by James Turnbull over 1 year ago

  • Status changed from Unreviewed to Investigating
  • Assignee set to Nigel Kersten

Nigel – this has come up before right?

Updated by Nigel Kersten over 1 year ago

absolutely. I’ve never used it myself, as firstly I don’t run puppetmasterd on OS X, and secondly MacPorts does this automatically for you when I do tests :)

I don’t know if there’s been a bug report before though.

Updated by Trevor Menagh over 1 year ago

We are in a situation where we have to use Mac OS X Server for our puppetmaster, and we didn’t want to use MacPorts for our installs (we are leaning towards Homebrew, if anything).

In any case, this isn’t an issue once you know what to do, it is just confusing when you are getting started. I understand the underlying issue is that on Mac OS X the nobody group is ­-2, and Ruby assigns the group ID as an unsigned integer making ­-2 become 4294967294 ( there is a thread about it at https://www.ruby-forum.com/topic/176925 ).

Updated by Nigel Kersten over 1 year ago

I’m curious why Homebrew is attractive?

Updated by James Turnbull over 1 year ago

  • Target version changed from 2.6.1 to 2.6.2

Updated by Jesse Wolfe over 1 year ago

  • Target version changed from 2.6.2 to 2.7.x

If this gets fixed in time, I’d like to see it in 2.6.2, but it’s a longstanding bug and shouldn’t block the release.

Updated by Nigel Kersten over 1 year ago

  • Status changed from Investigating to Accepted

Patch sent to dev list. We should have a resolution soon.

Updated by Nigel Kersten over 1 year ago

Given I’m not expecting crowds to clamour to look at the horror that is the directoryservices nameservice provider, I’ll whack the commit in here too:

http://github.com/nigelkersten/puppet/commit/efeb2f4d8d62073e037798b78280dadd2fc7713d

tests pass, seems to work fine, etc etc.

Updated by Nigel Kersten over 1 year ago

  • Status changed from Accepted to Ready For Checkin

Updated by Jesse Wolfe over 1 year ago

  • Status changed from Ready For Checkin to In Topic Branch Pending Review

Updated by Jesse Wolfe over 1 year ago

  • Status changed from In Topic Branch Pending Review to Ready For Checkin

Updated by Jesse Wolfe over 1 year ago

  • Status changed from Ready For Checkin to Merged - Pending Release
  • Branch set to http://github.com/puppetlabs/puppet/tree/next

Available in next at commit:85543a41978924a42490d0c3f1f5437c95b7c869

Updated by Nick Lewis about 1 year ago

  • Status changed from Merged - Pending Release to Closed

Updated by James Turnbull 7 months ago

  • Target version changed from 2.7.x to 2.7.0

Also available in: Atom PDF