I am trying to power on the virtual machines inside ESXi (manged by vCenter Server) using vSphere API. The OS I am using is Ubuntu 12.04 server.
I have a Java script that uses the API to do so, however, while powering on the VM, most of the times it gets stuck on the grub boot menu and never gets on from there.
I have changed the default grub settings on Ubuntu (in /etc/default/grub) machine to:
The VM boots up fine if I do it through the vSphere Client, and the problem occurs only while doing it through the API.
Any pointers would be much appreciated..
There is another grub option you may want to try.
For Ubuntu 12.04 LTS there is a specific option that can be set in /etc/default/grub.
For example, if you want to have a 2 seconds timeout (thus avoiding hangs for unattended reboots) just add the following line in /etc/default/grub:
Remember to run update-grub after that...