2

I use the knife ec2 plugin to bootstrap a new instance (Ubuntu 12.04) and install a software on it. Everything works great but after chef-client ends, some processes of the new software are killed. The weird thing is that this only appears with bootstrapping. If I bootstrap first a new instance and run the recipes afterwards this problem does not appear. As Chef Server I use hosted chef.
Any ideas what the problem could be?

2 Answers2

1

Linux will kill processes if the system is in danger of running out of memory [0], perhaps this is happening? grep /var/log/syslog for the phrase "oom" (can't remember if it is in capitals or not) - this will tell you if processes are being killed due to lack of memory.

0: http://linuxdevcenter.com/pub/a/linux/2006/11/30/linux-out-of-memory.html

Mike Ryan
  • 288
  • 2
  • 11
0

Check dmesg for out of memory errors

dmesg | grep OOM

This can happen almost surely if this is a micro instance you're running. In this case, add a swap file recipe before everything else (try this one: https://gist.github.com/4171136) and your issues will be over!

priestjim
  • 669
  • 3
  • 8