After installing Ubuntu 12.04 LTS as the only Operating System using a USB stick.
The computer boots only when the USB drive ( used to install Ubuntu 12.04 LTS ) is plugged in.
The boot manager Grub is written in the USB stick but not in the Hard Drive.
Install Grub on the Hard Drive
On this scenario I assume that the Hard Drive ( containing the OS ) is /dev/sda and that the boot order on BIOS contains this HD.
To find out the boot order for sure check the BIOS settings. To enter BIOS follow the instructions on the splash screen --hit one of these keys F2 , F12 , DEL , ESC , F10 while booting.
To figure out the name of the hard drive containing the OS hit Dash Home - Type "Terminal" -Fire up a Terminal and list your Hard Drive(s) Partitions with fdisk.
$ sudo fdisk -l
To Install Grub on /dev/sda
$ sudo grub-install /dev/sda $ sudo update-grub
$ sudo grub-install --recheck /dev/sdaRemove the USB stick and reboot.
$ sudo shutdown -r now
ubuntu 12.04 LTS boots only from USB