Cloud-init not first booting


#1

Hi guys,

I’m using http://cloudinit.readthedocs.io/en/latest/topics/examples.html#install-and-run-chef-recipes via aws ec2 run-instances --user-data file://cloud-init.yaml on Ubuntu Xenial running Cloud-init v. 0.7.7 and I’m running into an issue where the machine installs and runs chef but doesn’t do the initial “first boot” stage.

It seems similar to http://stackoverflow.com/a/28319899 but not quite the same.

And my /var/log/chef/client.log looks like

 # Logfile created on 2016-07-11 01:50:06 +0000 by logger.rb/v1.2.7
[2016-07-11T01:50:06+00:00] INFO: Daemonizing..
[2016-07-11T01:50:06+00:00] INFO: Forked, in 8622. Privileges: 0 0
[2016-07-11T01:50:08+00:00] FATAL: Chef is already running pid 8622

Is there something I am missing?

As a workaround, I am having to ssh into the system and run sudo chef-client --once to kick it off.