[chef] trouble using knife bootstrap on RHEL 5.5


Chronological Thread 
  • From: < >
  • To:
  • Subject: [chef] trouble using knife bootstrap on RHEL 5.5
  • Date: Fri, 21 Oct 2011 07:26:16 -0700 (PDT)

Chef folks,

I have several RHEL 5.5 VMs (call them A, B, C, …) on which I would like to
use chef.  I need to get A configured so that it can run knife bootstrap to 
set
up B, C, … as chef clients.  I’m running into a problem when I try running
knife bootstrap on A.   Here are the details.

A, B, C, … are part of a computing farm that is isolated from the outside
world – no access to the RedHat repos, no access to the normal gem repos. 
We’ve set up a chef server inside the farm, and mirrored the    repos inside
the farm.  I start with A, B, C, …  as  unadorned RHEL 5.5 images, and get
ssh access set up from A to B, C, … .   I bring A to the point where it can
run knife (install gcc, Ruby 1.8.7, RubyGems, etc.) , and try to run knife
bootstrap in A to bring up B.   Here’s what I see:

knife bootstrap tn7cretapp02 -VV --run-list 'recipe[dos]' --distro dos-eat
--sudo --ssh-user ******

/usr/lib/ruby/gems/1.8/gems/net-ssh-2.1.4/lib/net/ssh/transport/cipher_factory.rb:52:in
`padding=': padding=() function is unimplemented on this machine
(NotImplementedError)
                from
/usr/lib/ruby/gems/1.8/gems/net-ssh-multi-1.1/lib/net/ssh/multi/session_actions.rb:37:in
`join'
                from
/usr/lib/ruby/gems/1.8/gems/net-ssh-multi-1.1/lib/net/ssh/multi/session_actions.rb:37:in
`sessions'
                from
/usr/lib/ruby/gems/1.8/gems/net-ssh-multi-1.1/lib/net/ssh/multi/session_actions.rb:37:in
`each'
                from
/usr/lib/ruby/gems/1.8/gems/net-ssh-multi-1.1/lib/net/ssh/multi/session_actions.rb:37:in
`sessions'
                from
/usr/lib/ruby/gems/1.8/gems/net-ssh-multi-1.1/lib/net/ssh/multi/session_actions.rb:81:in
`open_channel'
                from
/usr/lib/ruby/gems/1.8/gems/chef-0.10.4/lib/chef/knife/ssh.rb:160:in
`ssh_command'
                from
/usr/lib/ruby/gems/1.8/gems/chef-0.10.4/lib/chef/knife/ssh.rb:341:in `run'
                from
/usr/lib/ruby/gems/1.8/gems/chef-0.10.4/lib/chef/knife/bootstrap.rb:153:in
`run'
                from
/usr/lib/ruby/gems/1.8/gems/chef-0.10.4/lib/chef/knife.rb:391:in
`run_with_pretty_exceptions'
                from
/usr/lib/ruby/gems/1.8/gems/chef-0.10.4/lib/chef/knife.rb:166:in `run'
                from
/usr/lib/ruby/gems/1.8/gems/chef-0.10.4/lib/chef/application/knife.rb:128:in
`run'
                from /usr/lib/ruby/gems/1.8/gems/chef-0.10.4/bin/knife:25
                from /usr/bin/knife:19:in `load'
                from /usr/bin/knife:19

Any idea what’s wrong?  If it’s a help, the script I use to configure A is
below.

Thanks for the help,

Jeff

--------------------------------------------------------------------------------------------------

export WORK_DIR=/tmp/chef-installer
mkdir -p ${WORK_DIR}
cd ${WORK_DIR}

export CHEFSERVER=http://*******

# download a yum config file that configures yum to use EATs rpm repo
wget ${CHEFSERVER}/files/repos/disney_eat.repo

# move the yum repo config that points at the internal EAT repo into place
if [ ! -f /etc/yum.repos.d/disney_eat.repo ]; then
  mv disney_eat.repo /etc/yum.repos.d
fi

# make sure all previous traces of ruby are uninstalled
yum -y erase ruby
yum -y erase ruby-*1.8.5*
yum -y erase ruby-*1.8.7*
yum -y clean all
rm -rf /usr/lib/ruby

# install Ruby 1.8.7-p352
yum -y install gdbm ruby-libs ruby rubygems ruby-devel

# patch openssl library
wget
${CHEFSERVER}/files/tarballs/ruby-1.8.7/ruby-1.8.7-p352-ext-openssl-lib-patch.tgz
tar xzf ruby-1.8.7-p352-ext-openssl-lib-patch.tgz
cd /tmp/chef-installer/ruby-openssl-patch
./install.sh

# install chef-solo, chef-client, and knife using the Rubygem method
yum -y install rubygem-chef

cd ${WORK_DIR}
wget
${CHEFSERVER}/files/repos/DISNEY-EAT-BASE/kernel-headers-2.6.18-194.3.1.el5.x86_64.rpm
rpm -ih kernel-headers-2.6.18-194.3.1.el5.x86_64.rpm

yum -y install gcc44 gcc44-c++ automake autoconf make

ln -nsf /usr/bin/gcc44 /usr/bin/gcc
ln -nsf /usr/bin/g++44 /usr/bin/g++

yum -y install libxml2-devel libxslt-devel

wget ${CHEFSERVER}/files/tarballs/chef-client/chef-client-gems.zip
unzip -o chef-client-gems.zip
cd chef-client-gems
gem install netaddr --local
gem install chef --local


  • [chef] trouble using knife bootstrap on RHEL 5.5, jeff.stroomer, 10/21/2011

Archive powered by MHonArc 2.6.16.

§