[chef] Re: Re: Re: How to write the cookbook for third party ubuntu ppa?


Chronological Thread 
  • From: Kevin Nuckolls < >
  • To:
  • Subject: [chef] Re: Re: Re: How to write the cookbook for third party ubuntu ppa?
  • Date: Wed, 22 Aug 2012 09:01:26 -0500

On EC2 or Eucalyptus you have the ability to upload what they call "user-data" that the ubuntu images know how to pull down and use as a bit of configuration information. When using the knife-ec2 plugin I pass in an executable bash script with the --user-data parameter.

If you're not using one of those clouds, something similar may be available for what you're using. You can also just go into your base system image and turn off cloud-init completely. It defaults to being on, and defaults to running apt-get update which in some cases will conflict with the initial chef bootstrap.

Hope that helps!
-Kevin

On Wed, Aug 22, 2012 at 3:05 AM, Millisi < " target="_blank"> > wrote:
@kevin, In which user script do i've to put that
apt_upgrade: false attribute? Is it some cookbook or role?

Via Millisami'z iPhone
I've encountered this problem as well and I'm nearly certain that a background process is running apt-get update by default when you start up the Ubuntu image. My solution was to tell cloud-init not to run apt-get update by default. These 100 errors no longer come up.


Set apt_upgrade: false in your user data script.

Hope that helps. 

Bryan I bet that command you asked him to run will run because it's a race condition. By the time you log in to the Ubuntu box and run it, the background cloud-init is done and other systems can run apt just fine.

-Kevin

On Tuesday, August 21, 2012, Bryan McLellan wrote:
On Tue, Aug 21, 2012 at 11:14 AM, Sachin Sagar Rai < > wrote:
> FATAL: Chef::Exceptions::Exec: package[ruby] (base::install_ruby line 22)
> had an error: Chef::Exceptions::Exec: apt-get -q -y install ruby=4.8-0bbox1
> returned 100, expected 0

It looks like apt is failing for some reason.

What happens if you run "apt-get -q -y install ruby=4.8-0bbox1"?

Bryan




Archive powered by MHonArc 2.6.16.

§