Quality Control is an ongoing series of blog posts where I am moved in rare circumstances to document what is wrong with software or anything else I find significantly rough. The posts are meant to be constructive, and I hope others can see through the likely presence of frustration in my tone to get there.
facter-1.5.8:beijing> ruby install.rb --destdir=/net/silmaril/export/puppet ... facter-1.5.8:beijing>
Good.
puppet-2.6.4:beijing> more README Documentation (and detailed install instructions) can be found online at http://docs.puppetlabs.com/. Additional documentation can also be found at the Puppet Wiki: http://projects.puppetlabs.com/projects/puppet/wiki/ Generally, you need the following things installed: * Ruby >= 1.8.1 (earlier releases might work but probably not) * The Ruby OpenSSL library. For some reason, this often isn't included in the main ruby distributions. You can test for it by running 'ruby -ropenssl -e "puts :yep"'. If that errors out, you're missing the library. If your distribution doesn't come with the necessary library (e.g., on Debian and Ubuntu you need to install libopenssl-ruby), then you'll probably have to compile Ruby yourself, since it's part of the standard library and not available separately. You could probably just compile and install that one library, though. * The Ruby XMLRPC client and server libraries. For some reason, this often isn't included in the main ruby distributions. You can test for it by running 'ruby -rxmlrpc/client -e "puts :yep"'. If that errors out, you're missing the library. * Facter => 1.5.1 You can get this from < http://puppetlabs.com/projects/facter >
Maybe there’s a good reason, but why are you telling me all of these minimum requirements instead of just checking for it in the build/install process?
puppet-2.6.4:beijing> ruby install.rb --destdir=/net/silmaril/export/puppet which: no ronn in (/usr/bin:/bin:/sbin:/usr/sbin:/net/silmaril/export/puppet/usr/bin) Could not load facter; cannot install puppet-2.6.4:beijing>
WTF is ‘ronn’? This is a fully loaded RHEL 5.5 box I am on.
puppet-2.6.4:beijing> ruby install.rb --help which: no ronn in (/usr/bin:/bin:/sbin:/usr/sbin:/net/silmaril/export/puppet/usr/bin) Could not load facter; cannot install puppet-2.6.4:beijing>
Awesome!
puppet-2.6.4:beijing> ruby install.rb --fdgfsdgfds which: no ronn in (/usr/bin:/bin:/sbin:/usr/sbin:/net/silmaril/export/puppet/usr/bin) install: invalid option: --fdgfsdgfds install.rb:92:in `mkdir': Permission denied - /etc/puppet (Errno::EACCES) from install.rb:92:in `do_configs' from install.rb:492 puppet-2.6.4:beijing>
So you got an invalid argument, and continued to try to mkdir? That doesn’t seem smart.
I guess I’ll look at the source for install.rb in order to find the ronn reference?
# install.rb # ... begin if $haverdoc ronn = %x{which ronn} $haveman = true else $haveman = false end rescue puts "Missing ronn; skipping man page creation" $haveman = false end # ...
So much for displaying that error message. Why wouldn’t you also display that along with ‘$haveman = false’ after the else clause?
Whatever, let’s just try to address the fact that Facter is not found. I’m not chasing the ronn rabbit down a hole, even though it’s not clear to me if I need it or not or what the hell it is.
puppet-2.6.4:beijing> find /net/silmaril/export/puppet/usr -name fac\* /net/silmaril/export/puppet/usr/bin/facter /net/silmaril/export/puppet/usr/lib/ruby/site_ruby/1.8/facter.rb /net/silmaril/export/puppet/usr/lib/ruby/site_ruby/1.8/facter /net/silmaril/export/puppet/usr/lib/ruby/site_ruby/1.8/facter/facterversion.rb /net/silmaril/export/puppet/usr/lib/ruby/site_ruby/1.8/facter/util/fact.rb puppet-2.6.4:beijing>
Apparently /net/silmaril/export/puppet/usr/bin being in my PATH does not mean anything to the Ruby library search logic. This obviously isn’t Puppet’s fault.
Digging around, I find that I can set RUBYLIB for non-standard places holding Ruby libraries/modules.
export RUBYLIB=/net/silmaril/export/puppet/usr/lib ruby install.rb --destdir=/net/silmaril/export/puppet = FAIL export RUBYLIB=/net/silmaril/export/puppet/usr/lib/ruby ruby install.rb --destdir=/net/silmaril/export/puppet = FAIL export RUBYLIB=/net/silmaril/export/puppet/usr/lib/ruby/site_ruby ruby install.rb --destdir=/net/silmaril/export/puppet = FAIL export RUBYLIB=/net/silmaril/export/puppet/usr/lib/ruby/site_ruby/1.8 SUCCESS
And apparently search for Ruby libraries only works at some unknown-to-me level of directory traversal. This, too, obviously isn’t Puppet’s fault.
So far, this is a pantload of fun.