Advertisement
shokti

ubuntu 12.04 - headless virtualbox installation

Jan 21st, 2013
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.22 KB | None | 0 0
  1. add virtualbox repository to ubuntu:
  2. sudo nano /etc/apt/sources.list
  3.  
  4. add below anad save:
  5. deb http://download.virtualbox.org/virtualbox/debian precise contrib non-free
  6.  
  7. download virtualbox repo key:
  8. wget http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc
  9.  
  10. install virtualbox repo key:
  11. sudo apt-key add oracle_vbox.asc
  12.  
  13. update repository database:
  14. sudo apt-get update
  15.  
  16. upgrade installed packages:
  17. sudo apt-get upgrade
  18.  
  19. install virtualbox and unzip:
  20. sudo apt-get install linux-headers-$(uname -r) build-essential dkms
  21. sudo apt-get install virtualbox-4.2 unzip
  22.  
  23. Create /etc/default/virtualbox:
  24. sudo nano /etc/default/virtualbox
  25.  
  26. Add this one line to the file:
  27. VBOXWEB_USER=[USERNAME]
  28.  
  29. Add local user to vboxusers group:
  30. sudo adduser [USERNAME] vboxusers
  31.  
  32. download phpvirtualbox:
  33. wget http://phpvirtualbox.googlecode.com/files/phpvirtualbox-4.2-4.zip
  34.  
  35. Unzip phpvirtualbox:
  36. unzip phpvirtualbox-4.2-4.zip
  37.  
  38. Create the phpvirtualbox directory:
  39. sudo mkdir /var/www/phpvirtualbox
  40.  
  41. Copy the phpvirtualbox files to the folder /var/www/phpvirtualbox:
  42. sudo cp -R phpvirtualbox-4.2-4/* /var/www/phpvirtualbox
  43.  
  44. Prepare the phpvirtualbox config file:
  45. sudo cp /var/www/phpvirtualbox/config.php-example /var/www/phpvirtualbox/config.php
  46.  
  47. Edit config.php:
  48. sudo nano /var/www/phpvirtualbox/config.php
  49.  
  50. Update the $username and $password variable to match your local user:
  51. var $username = ''
  52. var $password = ''
  53.  
  54. You can now start the Virtualbox web service:
  55. sudo /etc/init.d/vboxweb-service start
  56.  
  57. Download VirtualBox Extension Pack. This package installs what you need to do remote desktop into the virtual machines:
  58. wget http://download.virtualbox.org/virtualbox/4.1.18/Oracle_VM_VirtualBox_Extension_Pack-4.1.18-78361.vbox-extpack
  59. wget http://download.virtualbox.org/virtualbox/4.2.4/Oracle_VM_VirtualBox_Extension_Pack-4.2.4-81684.vbox-extpack
  60. Install VirtualBox Extension Pack:
  61. sudo VBoxManage extpack install Oracle_VM_VirtualBox_Extension_Pack-4.2.4-81684.vbox-extpack
  62.  
  63. Restart the server:
  64. sudo shutdown -r now
  65.  
  66. access phpvirtualbox:
  67. go to http://ip_address/phpvirtualbox
  68. default user:admin
  69. default password: admin
  70. go to preferences to add your username and password.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement