After the virtualbox-ose (OpenSourceEdition) version is directly installed on the Server, an error always occurs when it is started: MyServer :~ #/Etc/init. d/virtualbox-osestart * StartingVirtualBoxhostnetworking... [OK] * StartingVirtualBoxkernelmo
After the virtualbox-ose (Open Source Edition) version is directly installed on the Server, an error is always prompted during startup:
MyServer:~#/etc/init.d/virtualbox-ose start* Starting VirtualBox host networking... [ OK ]* Starting VirtualBox kernel module vboxdrv* No suitable module for running kernel found.
Later found that the official website closed source version of the introduction, really very detailed: http://www.virtualbox.org/wiki/Linux_Downloads
MyServer:~#vi /etc/apt/sources.list
Add a sentence:
deb http://download.virtualbox.org/virtualbox/debian lucid contrib
MyServer:~#wget http://download.virtualbox.org/virtualbox/debian/Oracle_vbox.ascMyServer:~# apt-key add oracle_vbox.ascMyServer:~#wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | sudo apt-key add -MyServer:~# apt-get updateMyServer:~# apt-get install virtualbox-4.0
First running error:
MyServer:~# /etc/init.d/vboxdrv setup* Stopping VirtualBox kernel modules[ OK ]* Uninstalling old VirtualBox DKMS kernel modules[ OK ]* Trying to register the VirtualBox kernel modules using DKMSError! Your kernel headers for kernel 2.6.32-28-server cannot be found at/lib/modules/2.6.32-28-server/build or /lib/modules/2.6.32-28-server/source. * Failed, trying without DKMS* Recompiling VirtualBox kernel modules* Look at /var/log/vbox-install.log to find out what went wrong
Locate error log/var/log/vbox-install.log discovery prompt to install linux-headers-2.6.32-28-server
apt-get install linux-headers-2.6.32-28-server
Or
apt-get install linux-headers-`uname -r`apt-get install linux-headers-generic
It is normal to start again
MyServer:~# /etc/init.d/vboxdrv start* Starting VirtualBox kernel modules [ OK ]
Run Setup to see:
MyServer:~# /etc/init.d/vboxdrv setup* Stopping VirtualBox kernel modules[ OK ]* Uninstalling old VirtualBox DKMS kernel modules[ OK ]* Trying to register the VirtualBox kernel modules using DKMS [ OK ]* Starting VirtualBox kernel modules
If Failed, trying without DKMS appears after the Linux kernel upgrade
/etc/init.d/vboxdrv setup* Stopping VirtualBox kernel modules [ OK ]* Uninstalling old VirtualBox DKMS kernel modules [ OK ]* Removing old VirtualBox netadp kernel module [ OK ]* Removing old VirtualBox netflt kernel module [ OK ]* Removing old VirtualBox kernel module [ OK ]* Trying to register the VirtualBox kernel modules using DKMS* Failed, trying without DKMS* Recompiling VirtualBox kernel modules [ OK ]* Starting VirtualBox kernel modules [ OK ]
Install dkms.
apt-get install dkms
Now you can useCommon UserTo use the virtual machine.
Ubuntu1010 is an IDE Hard Drive System downloaded from the Internet.
Ubuntu1004 is a self-installed Sata hard drive system.
Before uploading a virtual machine image, you 'd better enable the Virtual Machine locally, clear the Cache of the nic mac addresses, and then shut down:
sudo rm /etc/udev/rules.d/70-persistent-net.rules
Create a Windows Virtual Machine
user@MyServer:~$VBoxManage createvm --name Ubuntu1010 --registerVirtual machine 'Ubuntu1010' is created and registered.UUID: b066726c-8559-48f1-b998-fd7ad742e7ceSettings file: '/home/user/VirtualBox VMs/Ubuntu1010/Ubuntu1010.vbox' user@MyServer:~$VBoxManage createvm --name Ubuntu1004 --registerVirtual machine 'Ubuntu1004' is created and registered.UUID: 9e2a7030-953e-4935-aad7-07de8269ab1cSettings file: '/home/www/VirtualBox VMs/Ubuntu1004/Ubuntu1004.vbox'
By the way, I will post my thoughts on how to delete virtual machines, including virtual machine files:
user@MyServer:~$VBoxManage unregistervm Ubuntu1004 --delete
Create the storage controller required by the VM
user@MyServer:~$VBoxManage storagectl Ubuntu1010 --name "IDE Controller" --add ide --controller PIIX4 --hostiocache onuser@MyServer:~$VBoxManage storagectl Ubuntu1004 --name "SATA Controller" --add sata --controller IntelAHCI --hostiocache on