If you install ubuntu  as a guest on virtual box, you need to do a couple of things to install the virtualbox  additions:
- Mount your ubuntu cd/iso from the virtualbox GUI.
 - Install GNU Compiler and header files (use the command uname -r and substitute it with KERNELVERSION in the command below)      
sudo apt-get install build-essential linux-headers-KERNELVERSION
 - Now mount the VirtualBoxAdditions cd/iso from the virtualbox GUI.
 - Run the VirtuaBox installer:     
sudo sh /media/cdrom/VBoxLinuxAdditions.run all
 - Restart the virtual machine and you are all done!