Quick script – start VirtualBox VM in headless mode at boot time

Technical, Technology
#! /bin/sh
# /etc/init.d/StartVM
#

#Edit these variables!
VMUSER=ico
VMNAMES='browserkiosk01 browserkiosk02 browserkiosk03 browserkiosk04'
POWEROFF=acpipowerbutton
case "$1" in
 start)
 echo "Starting VirtualBox VM..."
 for vmname in $VMNAMES
 do
 sudo -H -b -u $VMUSER /usr/bin/VBoxVRDP -s "$vmname"
 sleep 30
 done
 ;;
 stop)
 echo "Saving state of Virtualbox VM..."
 for vmname in $VMNAMES
 do
 sudo -H -u $VMUSER /usr/bin/VBoxManage controlvm "$vmname" $POWEROFF
 sleep 10
 done
 ;;
 *)
 echo "Usage: /etc/init.d/StartVM {start|stop}"
 exit 1
 ;;
esac
exit 0

http://askubuntu.com/questions/57220/start-vboxheadless-vm-at-startup

Nice tool to control Linux service startup – sysv-rc-conf

Technical, Technology

The tool should come with the standard repos.  So, just do:
sudo apt-get update
sudo apt-get install sysv-rc-conf

Run it by:
sudo sysv-rc-conf

It gives you a nice UI that you could see all service setting vs. rc levels. You could also simply move by cursor to whatever service you would like to change the startup setting. Hitting space bar toggles the setting.

Good tool!

c.f. http://superuser.com/questions/266040/how-do-you-disable-an-upstart-service-in-ubuntu-10-10