You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Launchpad user Lorin Hochstein(lorinh) wrote on 2012-03-20T20:17:38.451377+00:00
cloud-init can't be used to provision a base oneiric instance with Chef. You can't install Chef from packages because of bug #960564. If you try to install from gems instead, you'll get this error in /var/log/cloud-init.log:
Mar 20 19:59:21 domU-12-31-39-04-04-D6 [CLOUDINIT] init.py[WARNING]: Traceback (most recent call last):#12 File "/usr/lib/python2.7/dist-packages/cloudinit/CloudConfig/init.py", line 108, in run_cc_modules#012 cc.handle(name, run_args, freq=freq)#12 File "/usr/lib/python2.7/dist-packages/cloudinit/CloudConfig/init.py", line 72, in handle#012 [ name, self.cfg, self.cloud, cloudinit.log, args ])#12 File "/usr/lib/python2.7/dist-packages/cloudinit/init.py", line 309, in sem_and_run#012 func(*args)#12 File "/usr/lib/python2.7/dist-packages/cloudinit/CloudConfig/cc_chef.py", line 79, in handle#012 subprocess.check_call(['/usr/bin/chef-client', '-d', '-i', '1800', '-s', '20'])#12 File "/usr/lib/python2.7/subprocess.py", line 511, in check_call#012 raise CalledProcessError(retcode, cmd)#012CalledProcessError: Command '['/usr/bin/chef-client', '-d', '-i', '1800', '-s', '20']' returned non-zero exit status 1
The actual error:
root@domU-12-31-39-04-04-D6:~# /usr/bin/chef-client -d -i 1800 -s 20
Invalid gemspec in [/var/lib/gems/1.8/specifications/json-1.6.1.gemspec]: invalid date format in specification: "2011-09-18 00:00:00.000000000Z"
/usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require': no such file to load -- json (LoadError) from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/json_compat.rb:20
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/rest.rb:25
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/search/query.rb:21
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/mixin/language.rb:19
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/resource.rb:22
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/resource/file.rb:19
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/provider/file.rb:21
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/provider/cookbook_file.rb:20
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/providers.rb:20
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef.rb:25
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in require'
from /var/lib/gems/1.8/gems/chef-0.10.8/bin/chef-client:23
from /usr/bin/chef-client:19:in `load'
from /usr/bin/chef-client:19
The problem is in /var/lib/gems/1.8/specifications/json-1.6.1.gemspec, line 9:
Launchpad user Lorin Hochstein(lorinh) wrote on 2012-04-08T11:49:10.109015+00:00
This bug doesn't affect precise: you can install chef using either gems or package with precise (assuming you specify the GPG key for the opscode repo for packages).
Launchpad user Scott Moser(smoser) wrote on 2012-05-30T14:01:13.419889+00:00
Per the last comment, I'm marking this as "fix-released".
If you wish for this to be fixed in 11.10, please open an ubuntu task, and then target it to 11.10. However, this would be very low priority due to availability of an LTS without the bug.
This bug was originally filed in Launchpad as LP: #960576
Launchpad details
Launchpad user Lorin Hochstein(lorinh) wrote on 2012-03-20T20:17:38.451377+00:00
cloud-init can't be used to provision a base oneiric instance with Chef. You can't install Chef from packages because of bug #960564. If you try to install from gems instead, you'll get this error in /var/log/cloud-init.log:
Mar 20 19:59:21 domU-12-31-39-04-04-D6 [CLOUDINIT] init.py[WARNING]: Traceback (most recent call last):#12 File "/usr/lib/python2.7/dist-packages/cloudinit/CloudConfig/init.py", line 108, in run_cc_modules#012 cc.handle(name, run_args, freq=freq)#12 File "/usr/lib/python2.7/dist-packages/cloudinit/CloudConfig/init.py", line 72, in handle#012 [ name, self.cfg, self.cloud, cloudinit.log, args ])#12 File "/usr/lib/python2.7/dist-packages/cloudinit/init.py", line 309, in sem_and_run#012 func(*args)#12 File "/usr/lib/python2.7/dist-packages/cloudinit/CloudConfig/cc_chef.py", line 79, in handle#012 subprocess.check_call(['/usr/bin/chef-client', '-d', '-i', '1800', '-s', '20'])#12 File "/usr/lib/python2.7/subprocess.py", line 511, in check_call#012 raise CalledProcessError(retcode, cmd)#012CalledProcessError: Command '['/usr/bin/chef-client', '-d', '-i', '1800', '-s', '20']' returned non-zero exit status 1
The actual error:
root@domU-12-31-39-04-04-D6:~# /usr/bin/chef-client -d -i 1800 -s 20
Invalid gemspec in [/var/lib/gems/1.8/specifications/json-1.6.1.gemspec]: invalid date format in specification: "2011-09-18 00:00:00.000000000Z"
/usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require': no such file to load -- json (LoadError) from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/json_compat.rb:20
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/rest.rb:25
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/search/query.rb:21
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/mixin/language.rb:19
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/resource.rb:22
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/resource/file.rb:19
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/provider/file.rb:21
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/provider/cookbook_file.rb:20
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef/providers.rb:20
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/../lib/chef.rb:25
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
gem_original_require' from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in
require'from /var/lib/gems/1.8/gems/chef-0.10.8/bin/chef-client:23
from /usr/bin/chef-client:19:in `load'
from /usr/bin/chef-client:19
The problem is in /var/lib/gems/1.8/specifications/json-1.6.1.gemspec, line 9:
See: http://stackoverflow.com/questions/5771758/invalid-gemspec-because-of-the-date-format-in-specification
Is there some workaround that could be placed in the beginning of a cloud-init script to work around this?
The text was updated successfully, but these errors were encountered: