[chef] Problem starting chef-client in Getting Started with EC2 Rails Infrastructure


Chronological Thread 
  • From: Robert J Berger <rberger@runa.com>
  • To: chef@lists.opscode.com
  • Subject: [chef] Problem starting chef-client in Getting Started with EC2 Rails Infrastructure
  • Date: Tue, 14 Jul 2009 01:31:18 -0700

I think I followed all the instructions between Getting Started with EC2 Rails Infrastructure and Chef 0.7.0 on EC2 Rails Infrastructure Notes

When I got to the instruction to run chef-client:
chef-client -t `cat /etc/chef/validation_token` -j config/ops_master.json

I get the error:
/usr/lib/ruby/1.8/net/http.rb:2097:in `error!': 401 "Authorization Required" (Net::HTTPServerException)
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/rest.rb:232:in `run_request'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/rest.rb:95:in `post_rest'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/client.rb:227:in `authenticate'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/client.rb:74:in `run'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/application/client.rb:163:in `run_application'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/application/client.rb:161:in `loop'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/application/client.rb:161:in `run_application'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/lib/chef/application.rb:53:in `run'
from /usr/lib/ruby/gems/1.8/gems/chef-0.7.0/bin/chef-client:26
from /usr/bin/chef-client:19:in `load'
from /usr/bin/chef-client:19

It wasn't clear that if I was using the roles stuff if I still need to edit config/ops_master.json or leave it as:
{
  "run_list": [ "role[base]", "role[ops_master]" ]
}

Also  its not really clear how to set up the user associated with $ldap_user. Do you need to create the home dir manually before doing the .ssh stuff? If so where does the userid of the chown come from? From ldap? If so its not working for me maybe because I didn't get the chef-client to run properly?

Thanks!
__________________
Robert J Berger - CTO
Runa.com (Solana Systems Corp)
+1 408-838-8896




Archive powered by MHonArc 2.6.16.

§