VirtualBox 4.2.12 on Fedora 18/17, CentOS/Red Hat (RHEL) 6.4/5.9
Oracle VirtualBox is a powerful x86 and AMD64/Intel64 virtualization product for enterprise as well as home use. VirtualBox is a general-purpose full virtualizer for x86 hardware. Targeted at server, desktop and embedded use, it is now the only professional-quality virtualization solution that is also Open Source Software.
VirtualBox supports a large number of guest operating systems:
- Windows 3.x
- Windows NT 4.0
- Windows 2000
- Windows XP
- Windows Server 2003
- Windows Vista
- Windows 7
- DOS
- Linux (2.4, 2.6, 3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.7)
- Solaris
- OpenSolaris
- OpenBSD
This guide shows howto install VirtualBox 4.2 (currently 4.2.12) on Fedora 18/17/16/15, CentOS 6.4/6.3/5.9, Red Hat (RHEL) 6.4/6.3/6.2/6.1/6/5.9. This guide uses Virtual Box own yum repositories.
Note: Fedora 14 users can install VirtualBox 4.1, Fedora 13 users can install VirtualBox 4.0 and Fedora 12 users can install VirtualBox 3.2.
1. Change to root User
su - ## OR ## sudo -i |
2. Install Fedora or RHEL Repo Files
cd /etc/yum.repos.d/ ## Fedora 18/17/16/15/14/13/12 users wget http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo ## CentOS 6.4/6.3/6.2/6.1/6/5.9 and Red Hat (RHEL) 6.4/6.3/6.2/6.1/6/5.9 users wget http://download.virtualbox.org/virtualbox/rpm/rhel/virtualbox.repo |
3. Update latest packages and check your kernel version
Update packages
yum update |
Check that that you are running latest installed kernel version
Output of following commands version numbers should match:
rpm -qa kernel |sort |tail -n 1 uname -r |
Note: If you got kernel update or run older kernel than newest installed then reboot:
reboot |
4. Install following dependency packages
CentOS 6/5 and Red Hat (RHEL) 6/5 needs EPEL repository, install it with following command:
## CentOS 6 and RHEL 6 ## rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm ## CentOS 5 and RHEL 5 ## rpm -Uvh http://dl.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm |
yum install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-devel dkms ## PAE kernel users install ## yum install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-PAE-devel dkms |
5. Install VirtualBox Latest Version 4.2 (currently 4.2.12)
yum install VirtualBox-4.2 |
Note:
This command create automatically vboxusers group and VirtualBox user must be member of that group.
This command also build needed kernel modules.
Rebuild kernel modules with following command:
/etc/init.d/vboxdrv setup ## OR ## service vboxdrv setup |
6. Add VirtualBox User(s) to vboxusers Group
Replace user_name with your own user name or some another real user name.
usermod -a -G vboxusers user_name |
7. Start VirtualBox
Use launcher from menu or simply run:
VirtualBox |
Troubleshooting
If you have problems with KERN_DIR parameter or your kernel directory is not automatically detected then set KERN_DIR environment variable manually, using following method:
## Current running kernel on Fedora ## KERN_DIR=/usr/src/kernels/`uname -r` ## Current running kernel on CentOS and Red Hat (RHEL) ## KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m` ## Fedora example ## KERN_DIR=/usr/src/kernels/2.6.33.5-124.fc13.i686 ## CentOS and Red Hat (RHEL) example ## KERN_DIR=/usr/src/kernels/2.6.18-194.11.1.el5-x86_64 ## Export KERN_DIR ## export KERN_DIR |
Check also:
Install VirtualBox Guest Additions on Fedora, CentOS, Red Hat (RHEL)
332 Comments
Leave a Comment
Trackbacks/Pingbacks
- Howto Install VirtualBox (with yum) on Fedora 12, CentOS 5.4, Red … | Just linux! - [...] Go here to read the rest: Howto Install VirtualBox (with yum) on Fedora 12, CentOS 5.4, Red … [...]
- Upgrade to Fedora 13 from Fedora 12 with Preupgrade | if not true then false - [...] 10 on Fedora 13Install Sun Java (JDK, JRE) on Fedora 13Install Adobe AIR 1.5 and 2 on Fedora 13Install ...
- Fedora NetInstall (Net Install) with gPXE and BFO (boot.fedoraproject.org) | if not true then false - [...] on Fedora 13Install Adobe AIR 1.5 and 2 on Fedora 13Install Adobe (Acrobat PDF) Reader on Fedora 13Install VirtualBox ...
- Install VirtualBox Guest Additions on Fedora 13, CentOS 5.5, Red Hat (RHEL) 6 | If Not True Then False - [...] 6. Reboot guest systemrebootThen VirtualBox Guest Additions install is ready.Check also:Install VirtualBox (with yum) on Fedora, CentOS, Red Hat ...
- CentOS 5.5 Netinstall – Network Installation | If Not True Then False - [...] 5.5Install Sun/Oracle Java (JDK, JRE) 6 on CentOS 5.5Install Adobe AIR 1.5 and 2 on CentOS 5.5Install VirtualBox (with ...
- Como instalar o VirtualBox no Fedora « tiagopassos.com - [...] if !1 0 Compartilhe: fedora, linux, máquina virtual, virtualbox, [...]
- Delicious Bookmarks for March 22nd through March 23rd « Lâmôlabs - [...] Install VirtualBox 4.0.4 on Fedora 14/13, CentOS/Red Hat (RHEL) 5.5/6 – March 22nd ( tags: virtualbox fedora centos ...
- Install VirtualBox 4.0.4 on Fedora 14/13, CentOS/Red Hat (RHEL) 5.5/6 « Записки Миханика. - [...] Install VirtualBox 4.0.4 on Fedora 14/13, CentOS/Red Hat (RHEL) 5.5/6. Рубрика: C других сайтов, Linux, Новости ...
- How To Install VirtualBox In Fedora | JF Agno Freelance Web Consultant and Web Developer in Davao Philippines - [...] Thats it simple right here is the original source click here [...]
- Installing VirtualBox on our Linux Clients » CS SysAdmin - [...] Reference: http://www.if-not-true-then-false.com/2010/install-virtualbox-with-yum-on-fedora-centos-red-hat-rhel... [...]
Oracle VirtualBox is a powerful x86 and AMD64/Intel64 virtualization product for enterprise as well as home use. VirtualBox is a general-purpose full virtualizer for x86 hardware. Targeted at server, desktop and embedded use, it is now the only professional-quality virtualization solution that is also Open Source Software.
Thanks. I was looking for something like this and it was very helpful, since I’m fairly new with using Fedora distros.
Hi
I was fighting with “kernel loading” problem for several hours ..
[root@tupolew /]# /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
Error! Your kernel headers for kernel 2.6.32-71.el6.x86_64 cannot be found at
/lib/modules/2.6.32-71.el6.x86_64/build or /lib/modules/2.6.32-71.el6.x86_64/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
and what is not surprise for, try to guess what helped me ?
REBOOT ..
[root@tupolew /]# shutdown -r 0
Broadcast message from root@tupolew
(/dev/pts/0) at 11:03 …
The system is going down for reboot NOW!
[root@tupolew /]#
login as: root
Access denied
[email protected]’s password:
Last login: Tue Dec 6 10:31:33 2011
[root@tupolew ~]#
[root@tupolew ~]#
[root@tupolew ~]#
[root@tupolew ~]# /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules
Error! There are no instances of module: vboxhost
4.1.6 located in the DKMS tree.
[ OK ]
Trying to register the VirtualBox kernel modules using DKMS[ OK ]
Starting VirtualBox kernel modules [ OK ]
[root@tupolew ~]#
Hi bartekjamajka,
This is very normal situation, if you are not running latest kernel and then your kernel-headers and kernel-devel packages not match your running kernel.
I decide to make more clear this guides step 3, when you should reboot… :)
Hello,
I had a problem installing VIrtualbox on fedora 16. I followed your guide end got to the KERN_DIR part. But when i rebooted the system got stuck on:
Started SYSV late init script for live image…
What should i do?..
Did you do any other changes on your system?
If this is VirtualBox related problem then you could try to change another virtual console with ALT+F2, (ALT+F3, ATL+F4), login and then disable VirtualBox related stuffs from autostarting services, with following commands (as root):
Then reboot your system:
If it still fail, then a very high probability it have nothing to do with VirtualBox installation…
If you want later turn vbox services back to on boot, then run following commands:
Thanks for your suggestions. What i did is ‘yum history undo’ and it brought it back to where i started…So i’ll be doing it again carefully. It seems there was a problem with Xorg.
Now the other thing is that yum can’t get VirtualBox-4.1 from the repo. I have to download the package directly from
https://www.virtualbox.org/wiki/Linux_Downloads
so i suppose i have to install it with
tar -ivh VirtualBox-4.1*.rpm
This is what i first did.
It seems to me i read somewhere that VirtualBox had a problem with Xorg since Fedora 16. is this true?
Please post output of following commands:
ok.
What are the tags to use when i post output?
You can use following tags, if you want bash output:
Ending pre tag without space… :)
Well when i tried ‘yum install VirtualBox-4.1′, i got that:
I tried again though and it seems to work…
Sorry for the bothering
I’ll go through the configuration now
??? Add VirtualBox User to vboxusers Group
:(( …. but not by using wheel group … this is intended for giving admin stuff to normal users …
Instead:
/etc/group:
vboxusers:x:501:remke
->>> usermod -aG vboxusers remke
Hi remke,
Thanks for correction. It was typo on command…now this guide is updated… :)
Hi,
Can anyone help,
i cannot install VirtualBox-3.2 on CentOS 5.4 i386 .
i’ve updated the system,
installed:
kernel-devel; kernel-PAE-devel; kernel-xen;kernel-xen-devel;
nothing worked, always the same problem: Recompiling VirtualBox kernel module [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
Wat can i try next?
Hi danijelpg,
Could you post /var/log/vbox-install.log file content here?
Hi
i am trying to install VBox-3.2.6 on CentOS 5.4 i386
i have not installed KVM
i have installed “Development Tools” (gcc, make, automake…)
but i cannot install DKMS using: “yum install dkms”, anyone ones why???
and second, more important: when i try to install VBox i get then massage:
recompiling vbox kernel module FAILED
output from “rpm -qa kernel\* | sort” says then i have kernel-xen
and when i remove it because of installing kernel-PAE-devel, after attemp to reboot, system cannot reboot.
my questions are:
- how to install DKMS
- how to switch from kernel-xen to kernel-devel or kernel-PAE-devel
any PLEASE help!
What happen when you try to install DKMS? Please post all error messages?
Worked like a charm for my Fedora 13 x86_64 with KDE.
Thanks a lot.
RHEL6 does not work yet as the repo tries a directory that does not exist. However using the fedora13 version on RHEL6 works so you will need to use that repo instead (with some manual editing of the .repo file). Maybe you could add that to the oterwise great guide!
Hi Christian,
Thanks! Good point, I added this to guide.
Can anyone to help me to install Sun virtual box in fedora 13
Hi Charith,
Did you read this blog post about Installing Sun VirtualBox 3.2.8 on Fedora 13 and did you try installing Sun VirtualBox according to the instructions?
I have dkms installed and I have done everything as above but get the old message
Failed to open a session for the virtual machine win.
The virtual machine ‘win’ has terminated unexpectedly during startup with exit code 1.
When starting from command line “Virtualbox” I get
[root@embla yum.repos.d]# VirtualBox
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
available for the current kernel (2.6.33.3-85.fc13.i686) or it failed to
load. Please recompile the kernel module and install it by
sudo /etc/init.d/vboxdrv setup
You will not be able to start VMs until this problem is fixed.
WARNING: The compilation of the vboxdrv.ko kernel module failed during the
installation for some reason. Starting a VM will not be possible.
Please consult the User Manual for build instructions.
Qt WARNING: QGtkStyle was unable to detect the current GTK+ theme.
Qt WARNING: Qt: Session management error: None of the authentication protocols specified are supported
Any suggestions?
Hi Sarah,
Do you have Gnome installed?
This problem occurs because the system tries to detect the GTK+ theme, but it does not exist.
You can try to fix this in the following way
Start qtconfig-qt4 program:
And change another theme than GTK/GTK+ (QGtkStyle).
Thanks this is very helpful, the only thing is that I’m also getting the same error.
—————————————————————————————————-
No precompiled module for this kernel found — trying to build one. Messages
emitted during module compilation will be logged to /var/log/vbox-install.log.
Compilation of the kernel module FAILED! VirtualBox will not start until this
problem is fixed. Please consult /var/log/vbox-install.log to find out why the
kernel module does not compile. Most probably the kernel sources are not found.
Install them and execute
/etc/init.d/vboxdrv setup
as root.
—————————————————————————————————-
I have tried everything as explained there with out errors, I’m running Fedora 13 x64, this same problem is happening to me running ClearOS 5.2 and 5.1 (which is based on CentOS 5.5, I think), the exact same message, would you please give some advice ??
Thanks a lot again.
Hi Joe,
Are you getting the same qt4 errors or are you getting this “No precompiled module for this kernel found” error?
Please post what you get when you run following command (as root):
What to do with this?
# VirtualBox
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
available for the current kernel (2.6.31.5-127.fc12.i686.PAE) or it failed to
load. Please recompile the kernel module and install it by
sudo /etc/init.d/vboxdrv setup
You will not be able to start VMs until this problem is fixed.
Hi richard,
Try run following command (as root):
Hi!
When a VM I get this error in a window:
Error In suplibOsInit (window title)
Kernel driver not installed (rc=-1908)
The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a permission problem with /dev/vboxdrv. Please reinstall the kernel module by executing
‘/etc/init.d/vboxdrv setup’
as root. Users of Ubuntu, Fedora or Mandriva should install the DKMS package first. This package keeps track of Linux kernel changes and recompiles the vboxdrv kernel module if necessary.
Then I run /etc/init.d/vboxdrv setup
WARNING: All config files need .conf: /etc/modprobe.d/blacklist-vmc, it will be ignored in a future release.
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
Error! Bad return status for module build on kernel: 2.6.32.21-168.fc12.i686 (i686)
Consult the make.log in the build directory
/var/lib/dkms/vboxhost/3.2.10/build/ for more information.
[FALLÓ]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FALLÓ]
(Look at /var/log/vbox-install.log to find out what went wrong)
I have them GTK+
Thanks!!!!
ups!! I have Fedora 12
Hi antonio,
Could you post messages from /var/log/vbox-install.log file. After running following command (as root):
Hi JR,
Thank. Here vbox-install.log:
Uninstalling modules from DKMS
removing old DKMS module vboxhost version 3.2.10
------------------------------
Deleting module version: 3.2.10
completely from the DKMS tree.
------------------------------
Done.
Attempting to install using DKMS
Creating symlink /var/lib/dkms/vboxhost/3.2.10/source ->
/usr/src/vboxhost-3.2.10
DKMS: add Completed.
Kernel preparation unnecessary for this kernel. Skipping...
Building module:
cleaning build area....
make KERNELRELEASE=2.6.32.21-168.fc12.i686 -C /lib/modules/2.6.32.21-168.fc12.i686/build M=/var/lib/dkms/vboxhost/3.2.10/build....(bad exit status: 2)
0
0
Failed to install using DKMS, attempting to install without
make KBUILD_VERBOSE=1 -C /lib/modules/2.6.32.21-168.fc12.i686/build SUBDIRS=/tmp/vbox.0 SRCROOT=/tmp/vbox.0 modules
/usr/src/kernels/2.6.32.21-168.fc12.i686/scripts/gcc-version.sh: line 25: gcc: no se encontró la orden
/usr/src/kernels/2.6.32.21-168.fc12.i686/scripts/gcc-version.sh: line 26: gcc: no se encontró la orden
/usr/src/kernels/2.6.32.21-168.fc12.i686/arch/x86/Makefile:81: stack protector enabled but no compiler support
make[1]: gcc: No se encontró el programa
test -e include/linux/autoconf.h -a -e include/config/auto.conf || ( \
echo; \
echo " ERROR: Kernel configuration is invalid."; \
echo " include/linux/autoconf.h or include/config/auto.conf are missing."; \
echo " Run 'make oldconfig && make prepare' on kernel src to fix it."; \
echo; \
/bin/false)
mkdir -p /tmp/vbox.0/.tmp_versions ; rm -f /tmp/vbox.0/.tmp_versions/*
make -f scripts/Makefile.build obj=/tmp/vbox.0
gcc -Wp,-MD,/tmp/vbox.0/linux/.SUPDrv-linux.o.d -nostdinc -isystem -Iinclude -I/usr/src/kernels/2.6.32.21-168.fc12.i686/arch/x86/include -include include/linux/autoconf.h -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -fno-delete-null-pointer-checks -Os -msoft-float -mregparm=3 -freg-struct-return -march=i686 -ffreestanding -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-omit-frame-pointer -fno-optimize-sibling-calls -g -pg -I/lib/modules/2.6.32.21-168.fc12.i686/build/include -I/tmp/vbox.0/ -I/tmp/vbox.0/include -I/tmp/vbox.0/r0drv/linux -I/tmp/vbox.0/vboxdrv/ -I/tmp/vbox.0/vboxdrv/include -I/tmp/vbox.0/vboxdrv/r0drv/linux -D__KERNEL__ -DMODULE -DRT_OS_LINUX -DIN_RING0 -DIN_RT_R0 -DIN_SUP_R0 -DVBOX -DRT_WITH_VBOX -DVBOX_WITH_HARDENING -DCONFIG_VBOXDRV_AS_MISC -DRT_ARCH_X86 -DVBOX_WITH_64_BITS_GUESTS -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(SUPDrv_linux)" -D"KBUILD_MODNAME=KBUILD_STR(vboxdrv)" -D"DEBUG_HASH=27" -D"DEBUG_HASH2=27" -c -o /tmp/vbox.0/linux/SUPDrv-linux.o /tmp/vbox.0/linux/SUPDrv-linux.c
/bin/sh: gcc: no se encontró la orden
make[2]: *** [/tmp/vbox.0/linux/SUPDrv-linux.o] Error 127
make[1]: *** [_module_/tmp/vbox.0] Error 2
make: *** [vboxdrv] Error 2
I do not understand Spanish well, but it seems that gcc does not exist. So try following (as root):
Then run following again:
Does it work then? Or do you receive more errors?
JR,
Sorry, I did not realize it was in Spanish.
Installing gcc, Virtualbox works correctly!!!!
Thanks!!!!
No problem, with Spanish :) I would have asked more specifically if I had not got it translated myself :)
Nice to hear that you got it working correctly!
You’re welcome!
Thanks for this information – I had the same error in virtualbox using Fedora 16 and installing gcc fixed the problem!
Hi,
Your post was really helpfull, I installed GCC on Centos and the VM is working fine now
Errors I am getting trying to get Virtual Box running on Oracle Linux(Red Hat Enterprise Linux Server release 5.5 (Tikanga))
[root@tag5263 ~]# /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
Error! Your kernel source for kernel 2.6.18-194.el5 cannot be found at
/lib/modules/2.6.18-194.el5/build or /lib/modules/2.6.18-194.el5/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
[root@tag5263 ~]#
Any help would be appreciated I tried everything I read in the article and comments.
Hi Woodsman,
Could you post messages from /var/log/vbox-install.log file. After running following command (as root):
I got a problem when I try to start using VirtualBox. This is Fedora 13 & here I post the error message from the terminal screen:
[root@localdomain yum.repos.d]# VirtualBox
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
available for the current kernel (2.6.34.7-61.fc13.i686.PAE) or it failed to
load. Please recompile the kernel module and install it by
sudo /etc/init.d/vboxdrv setup
You will not be able to start VMs until this problem is fixed.
So I follow the instruction then there is the result:
[root@localdomain yum.repos.d]# sudo /etc/init.d/vboxdrv setup
WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMS
Error! Your kernel source for kernel 2.6.34.7-61.fc13.i686.PAE cannot be found at
/lib/modules/2.6.34.7-61.fc13.i686.PAE/build or /lib/modules/2.6.34.7-61.fc13.i686.PAE/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
And there is the message in “/var/log/vbox-install.log”:
Uninstalling modules from DKMS
removing old DKMS module vboxhost version 3.2.10
——————————
Deleting module version: 3.2.10
completely from the DKMS tree.
——————————
Done.
Attempting to install using DKMS
Creating symlink /var/lib/dkms/vboxhost/3.2.10/source ->
/usr/src/vboxhost-3.2.10
DKMS: add Completed.
You can use the –kernelsourcedir option to tell DKMS where it’s located.
Failed to install using DKMS, attempting to install without
Makefile:159: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR= and run Make again. Stop.
I am a beginner of Linux so please help to describe the problem, any help will be appreicated! ^_^
Hi K2,
Could you post messages from /var/log/vbox-install.log file. After running following command (as root):
Also you could try following:
Then do following:
Then try run following again:
Thanks for your help, JR! :D
I followed your instruction & copy the result below:
[root@localdomain yum.repos.d]# /etc/init.d/vboxdrv setup
WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMS
Error! Your kernel source for kernel 2.6.34.7-61.fc13.i686.PAE cannot be found at
/lib/modules/2.6.34.7-61.fc13.i686.PAE/build or /lib/modules/2.6.34.7-61.fc13.i686.PAE/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
[root@localdomain yum.repos.d]# yum install gcc kernel-devel kernel-headers
Loaded plugins: presto, refresh-packagekit
rpmfusion-free-updates | 3.3 kB 00:00
updates/metalink | 5.0 kB 00:00
updates | 4.7 kB 00:00
updates/primary_db | 4.1 MB 00:07
virtualbox | 951 B 00:00
Setting up Install Process
Package gcc-4.4.4-10.fc13.i686 already installed and latest version
Package kernel-devel-2.6.34.7-61.fc13.i686 already installed and latest version
Package kernel-headers-2.6.34.7-61.fc13.i686 already installed and latest version
Nothing to do
[root@localdomain yum.repos.d]# KERN_DIR=/usr/src/kernels/’uname -r’
[root@localdomain yum.repos.d]# export KERN_DIR
[root@localdomain yum.repos.d]# /etc/init.d/vboxdrv setup
WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMS
Error! Your kernel source for kernel 2.6.34.7-61.fc13.i686.PAE cannot be found at
/lib/modules/2.6.34.7-61.fc13.i686.PAE/build or /lib/modules/2.6.34.7-61.fc13.i686.PAE/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
And this is the messages from /var/log/vbox-install.log file:
Uninstalling modules from DKMS
removing old DKMS module vboxhost version 3.2.10
——————————
Deleting module version: 3.2.10
completely from the DKMS tree.
——————————
Done.
Attempting to install using DKMS
Creating symlink /var/lib/dkms/vboxhost/3.2.10/source ->
/usr/src/vboxhost-3.2.10
DKMS: add Completed.
You can use the –kernelsourcedir option to tell DKMS where it’s located.
Failed to install using DKMS, attempting to install without
/bin/sh: line 0: test: /usr/src/kernels/uname: binary operator expected
Makefile:177: *** Error: KERN_DIR does not point to a directory. Stop.
Please let me know if any idea to fix this, thanks! ^_^
Thanks for your help, JR! :D
I followed your instruction & copy the result below:
[root@localdomain yum.repos.d]# /etc/init.d/vboxdrv setup
WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMS
Error! Your kernel source for kernel 2.6.34.7-61.fc13.i686.PAE cannot be found at
/lib/modules/2.6.34.7-61.fc13.i686.PAE/build or /lib/modules/2.6.34.7-61.fc13.i686.PAE/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
[root@localdomain yum.repos.d]# yum install gcc kernel-devel kernel-headers
Loaded plugins: presto, refresh-packagekit
rpmfusion-free-updates | 3.3 kB 00:00
updates/metalink | 5.0 kB 00:00
updates | 4.7 kB 00:00
updates/primary_db | 4.1 MB 00:07
virtualbox | 951 B 00:00
Setting up Install Process
Package gcc-4.4.4-10.fc13.i686 already installed and latest version
Package kernel-devel-2.6.34.7-61.fc13.i686 already installed and latest version
Package kernel-headers-2.6.34.7-61.fc13.i686 already installed and latest version
Nothing to do
[root@localdomain yum.repos.d]# KERN_DIR=/usr/src/kernels/’uname -r’
[root@localdomain yum.repos.d]# export KERN_DIR
[root@localdomain yum.repos.d]# /etc/init.d/vboxdrv setup
WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMS
Error! Your kernel source for kernel 2.6.34.7-61.fc13.i686.PAE cannot be found at
/lib/modules/2.6.34.7-61.fc13.i686.PAE/build or /lib/modules/2.6.34.7-61.fc13.i686.PAE/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
And this is the messages from /var/log/vbox-install.log file:
Uninstalling modules from DKMS
removing old DKMS module vboxhost version 3.2.10
——————————
Deleting module version: 3.2.10
completely from the DKMS tree.
——————————
Done.
Attempting to install using DKMS
Creating symlink /var/lib/dkms/vboxhost/3.2.10/source ->
/usr/src/vboxhost-3.2.10
DKMS: add Completed.
You can use the –kernelsourcedir option to tell DKMS where it’s located.
Failed to install using DKMS, attempting to install without
/bin/sh: line 0: test: /usr/src/kernels/uname: binary operator expected
Makefile:177: *** Error: KERN_DIR does not point to a directory. Stop.
Please let me know if any idea to fix this, thanks! ^_^
Sometimes it is soooo hard to love Fedora, but all of my problems have been solved with info on your site – thank you so much! Beats posting on forums and getting patronising responses from people who haven’t bothered to read actual problem! Thank you again!
Hi MissyB, nice to see you here! :)
Glad to hear that my site has been helpful to you! And feel free to ask if you have any problems. I will try my best to answer… :)
Hi,
Thank you so much for your great post. I have just completed set-up virtualbox on my Centos VPS by simply copying and pasting the commands. Keep up great job. I’ll be back if I need further help.
Thanks
Can someone type what needs to be reconfigured in the Kernel? This is the spot i am stuck on.
the RC–1908 not installed is the issue
where is this to be pasted?!
## Current running kernel on Fedora ##
KERN_DIR=/usr/src/kernels/`uname -r`
## Current running kernel on CentOS and Red Hat (RHEL) ##
KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m`
## Fedora example ##
KERN_DIR=/usr/src/kernels/2.6.33.5-124.fc13.i686
## CentOS and Red Hat (RHEL) example ##
KERN_DIR=/usr/src/kernels/2.6.18-194.11.1.el5-x86_64
## Export KERN_DIR ##
export KERN_DIR
I am new to Fedora ………..I have successfully installed all steps accept this one……
Add KERN_DIR environment variable
## Current running kernel on Fedora ##
KERN_DIR=/usr/src/kernels/`uname -r`
## Current running kernel on CentOS and Red Hat (RHEL) ##
KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m`
## Fedora example ##
KERN_DIR=/usr/src/kernels/2.6.33.5-124.fc13.i686
## CentOS and Red Hat (RHEL) example ##
KERN_DIR=/usr/src/kernels/2.6.18-194.11.1.el5-x86_64
## Export KERN_DIR ##
export KERN_DIR
can someone tell me what this means?
Hi Brian,
On Fedora paste following lines to console as root:
Then install VirtualBox using YUM (as root):
Or if you have already installed VirtualBox then setup vbox kernel drivers with following command (as root):
I tried the following steps……… only to receive a failed error………….then i opened by
sudo gedit /etc/init.d/vboxdrv setup
now that I have vboxdrv setp opened w gedit text editor any advice on wht needs to be compiled?
Do not edit vboxdrv init script, because it should work quite right.
Please post full error messages what you get?
/lib/modules//lib/modules/2.6.35.6-48.fc14.i686.PAE/build
in this link………it says the link is broken in the /build
RC–1908 KERNEL not installed
How can this be taken care of?
Hi rosco,
First install following packages:
Set KERN_DIR environment variable:
Then install VirtualBox or run kernel driver setup:
How can i solved this problem I’m using Fedora 14
GLib-GIO:ERROR:gdbusconnection.c:2270:initable_init: assertion failed: (connection->initialization_error == NULL)
Aborted (core dumped)
Hi Romz,
Are you sure that you installed the correction version of VirtualBox?
Could you post full output from console after running VirtualBox command?
And following command output:
besides being root………what else do you key in before this?
## Current running kernel on Fedora ##
KERN_DIR=/usr/src/kernels/`uname -r`
## Current running kernel on CentOS and Red Hat (RHEL) ##
KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m`
## Export KERN_DIR ##
export KERN_DIR
every since i started using Fedora 14.I cannot use the virtual machines! none of them!
YOUV’E GOT TO BE MORE SPECIFIC !
WILL YOU PLEASE SET AN EXAMPLE FOR THOSE WHOM NEVER USED FEDORA?
WHAT DOES KERN_DIR mean? do I change uname with something else?
is there any tutorials on seting KERN_DIR?
KERN_DIR=/usr/src/kernels/`uname -r`
## Current running kernel on CentOS and Red Hat (RHEL) ##
KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m`
## Export KERN_DIR ##
export KERN_DIR
Hi earl,
You should simply run following commands on Fedora as root:
You could also use following method:
Is this specific enough? Did you get the point?
this is what i keyed in
KERN_DIR=/usr/src/kernels/2.6.35.9-64.fc14.i686
yes.this is my kernel
followed by
export
where is my error?!
Hi Clyde,
If your kernel release is 2.6.35.9-64.fc14.i686 then just run following:
Check more information from here.
I have tried almost every solution given here, and I still have this problem
[root@unkown Apuesto]# sudo /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
Error! Your kernel source for kernel 2.6.34.7-63.fc13.i686.PAE cannot be found at
/lib/modules/2.6.34.7-63.fc13.i686.PAE/build or /lib/modules/2.6.34.7-63.fc13.i686.PAE/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
[root@unkown Apuesto]#
Then the log from /var/log/vbox-install.log
Uninstalling modules from DKMS
removing old DKMS module vboxhost version 3.2.12
——————————
Deleting module version: 3.2.12
completely from the DKMS tree.
——————————
Done.
Attempting to install using DKMS
Creating symlink /var/lib/dkms/vboxhost/3.2.12/source ->
/usr/src/vboxhost-3.2.12
DKMS: add Completed.
You can use the –kernelsourcedir option to tell DKMS where it’s located.
Failed to install using DKMS, attempting to install without
Makefile:159: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR= and run Make again. Stop.
Any one with suggestions? Am trying to install windows 7 on the virtual box.
Hi Apuesto,
Did you specify KERN_DIR environment variable?
If yes then please post output of following commands:
The output
[root@unkown Apuesto]# yum list installed gcc kernel-devel kernel-headers
Loaded plugins: presto, refresh-packagekit
Installed Packages
gcc.i686 4.4.5-2.fc13 @updates
kernel-devel.i686 2.6.34.7-63.fc13 @updates
kernel-headers.i686 2.6.34.7-63.fc13 @updates
[root@unkown Apuesto]# uname -a
Linux unkown 2.6.34.7-63.fc13.i686.PAE #1 SMP Fri Dec 3 12:28:58 UTC 2010 i686 i686 i386 GNU/Linux
Looks good.
Did you specify KERN_DIR environment variable, like:
Then you could install/reinstall VirtualBox or run vboxdrv setup:
JR,
You just gave me the best Christmas gift ever!
I had struggled with this for a couple of days, got it working on RH4, but had a heck of time with RH6,
I read your article, tried it again, still failed… then I re-read your article again, slooooowly, and followed your instructions to the letter, and…. finally I have it working.
Thanks so much for your detailed instructions, they work.
I am a somewhat newbie to Linux, been around Solaris for a while, but lot’s to learn.
I am on my way to Windoze independence.
Thanks again, and have a great Christmas!
I finally got it! The parts I was not installing make & automake!
Those of you like me and Apuesto who have a PAE kernel…. you need to install the PAE kernel sources
yum install kernel-PAE-devel.i686
Chris
Good point caver! :)
Added to guide…thanks!
I tried everything listed and sure enough this was my answer! Thank you everyone!
This has got to be the easiest virtualbox installs I’ve ever seen. The first time I did this set, I followed some other idiots instructions and it was a nightmare!
thanks for posting something truly useful!
Do you have to uninstall VBox 3.x prior to installing Vbox 4.x?
Do you need to shutdown the network translation services prior to to an update.
I am getting collisions with files that 3.x says it needs when installing 4.x so just trying to make sure I have the correct install flow.
Thanks,
TomT…
Hi Thomas,
I think uninstalling VirtualBox 3.x and reinstall VirtualBox 4.x should be enough to get Virtualbox 4.x up and running. At least for myself, it worked out correctly, but if you have something valuable data related to VirtualBox 3.x installation, then you should take backup of them. For me this method uninstall VBox 3.x and reinstall VBox 4.x had no effect on any virtual machines (I have several virtual machines), but course it’s better to do it as safe as possible.
JR, Thanks just wish they would add that to the FAQ that uninstalling previous version may be necessary; the VB folks make is sound like this Upgrade should just overright the previous one with issues. For those of us that just run the “Stock” vbox configuration — if there is such a thing — I would expect it to work that way. Not that I was shy from doing what I suggested; just wanted to make sure I didn’t miss something obvious.
TomT…
I agree with you that this should definitely be added to FAQ.
Hi JR,
your site always help me a lot.
I fallow every step when intall vbox in fedora 13/14 but… now in have a problem
I don’t know if is just me or the virtualbox.repo doesn’t work. Because when in did the “yum update” it return me an error that can not find the url of the repo info.
thus I erased the repo and download the rpm directly from virtualbox.org and installed it, after that I do the following steps and works perfectly, only that I don’t have virtualbox.repo jejeje
sorry for my bad english
¡un saludo!
hi
when i try to run the vbox i alyays get a message that:———-
this kernel requires an x86-64, but only detected an i686 cpu
unable to boot – please use a kernel appropriate for your cpu.
—————-
please help me out.
prash
Hi prash,
Which processor do you use 32-bit or 64-bit?
got the following error
Makefile:178: *** Error: KERN_DIR does not point to a directory. Stop
Hi sanam,
Could you print your KERN_DIR variable and post here?
Your guide instructions worked and I was able to get VirtualBox running without a problem. Now I’m trying to get my XP guest to print. When I try to get usb2 working, I get a box saying that I need to install Oracle Vm Extension Pack. From what I’ve found, that should have been installed from your guide. Once I get VB working, I guess I need another guide to connect to the printer.
Hi pottzie,
Install it with following method:
1. Download Oracle VM Extension Pack. It found also here.
2. Open VirtualBox
3. Select File > Preferences… > Extensions
4. Click Add Package icon
5. Select package from your disk
6. Install it with “installer”
Then try again, did you get it working? And note it’s free only for personal use…
Hi Jr i your website very helpful. However iam stuck in situation like them … I did the following
1.Downloaded here in this http://www.virtualbox.org/wiki/Linux_DownloadsDownload it and Save it in Downloads.
2. Went the terminal did the: sudo rpm -Uvh cd/location/virtualbox-idownloaded . Press Enter …if it perfectly goes along just fine then..
3.First Error: Failed dependencies: libSDL-1.2.so.0 is needed by VirtualBox-4.1-4.1.0_73009_fedora14-1.i686
So i went to the Terminal and type: sudo yum install libSDL-*
4. Second Error:No precompiled module for this kernel found — trying to build one. Messages
emitted during module compilation will be logged to /var/log/vbox-install.log.
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMS [FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
and so i put to the terminal: yum install gcc kernel-devel kernel-headers
By this time i went to my menu and found my Oracle VM. However i encountered an error after installing and now running the xp that i installed.
it says:
Pop up:
Kernel driver not installed (rc=-1908) The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a permission problem with /dev/vboxdrv. Please reinstall the kernel module by executing ‘/etc/init.d/vboxdrv setup’ as root. Users of Ubuntu, Fedora or Mandriva should install the DKMS package first. This package keeps track of Linux kernel changes and recompiles the vboxdrv kernel module if necessary.
so i installed : Go to terminal and type: sudo yum install dkms
then i typed: sudo /etc/init.d/vboxdrv setup
still the same error is coming after i typed this : sudo /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
Error! Your kernel source for kernel 2.6.35.6-45.fc14.i686 cannot be found at
/lib/modules/2.6.35.6-45.fc14.i686/build or /lib/modules/2.6.35.6-45.fc14.i686/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
In the log File :
You can use the –kernelsourcedir option to tell DKMS where it’s located.
Failed to install using DKMS, attempting to install without
Makefile:172: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR= and run Make again. Stop.
then i did this
sudo yum install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-devel
then the output was still this :
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMS[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
i also did the instruction you wrote there which is:
## Set KERN_DIR environment variable with following command ##
KERN_DIR=/usr/src/kernels/`uname -r`
## You could verify what happens after this command with following command ##
echo $KERN_DIR
## Output Shouls look something like following ##
/usr/src/kernels/2.6.35.9-64.fc14.i686
## Then export KERN_DIR environment variable ##
export KERN_DIR
this is kinda drivin me nuts: help!
oh btw i checked the kernels/2.6.35.9-64.fc14.i686
ls it
and saw the build and source in red. tried to open it and it was empty.
Hi Roche,
Could you post output of following command:
Hi jr
here :
uname -a
Linux localhost.localdomain 2.6.35.6-45.fc14.i686 #1 SMP Mon Oct 18 23:56:17 UTC 2010 i686 i686 i386 GNU/Linux
rpm -qa|grep kernel-
*kernel-2.6.35.6-45.fc14.i686
kernel-devel-2.6.35.13-92.fc14.i686
abrt-addon-kerneloops-1.1.13-2.fc14.i686
kernel-headers-2.6.35.13-92.fc14.i686
Hi again Roche,
The problem seems to be in the fact that you have a different version of the kernel, than kernel-devel and kernel-headers packages are. So you have to upgrade your kernel and reboot…so simply do following:
yum update kernel kernel-devel kernel-headers rebootCheck that the all versions match and then try to set KERN_DIR again and run:
Btw. I recommend to use VirtualBox yum repos and I updated this guide also to VB 4.1 version… :)
Thank you very much JR. :)
Wow ! this is awesome.! worked perfectly on my centos 5.6
I successfully installed and run VirtualBox on fedora 14, but i notice an error while shutting down my machine, the error said panic occurred switching back text to console. Google cant answer my query so I decided to put it here. Thanks in Advance ^_^
thanks for this stuff JR, it works. but when im going to shut down my fedora machine, i got an error near shutdown, last line is panic occurred switching back text to console.
Hi openx,
Do you get that error on virtual machine or your host machine?
Hi. I am trying to install virtualbox-4.1 on ubuntu 11.04.
I actually updated my previous version of ubuntu to this.
When i try to open my virtualbox-4.1. I am get the following error.
Kernel driver not installed (rc=-1908)
The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a permission problem with /dev/vboxdrv. Please reinstall the kernel module by executing
‘/etc/init.d/vboxdrv setup’
as root. Users of Ubuntu, Fedora or Mandriva should install the DKMS package first. This package keeps track of Linux kernel changes and recompiles the vboxdrv kernel module if necessary.
when i give ‘/etc/init.d/vboxdrv setup’ as a root it shows error like this.
root@karthick-pc:/home/karthick_sj88# /etc/init.d/vboxdrv setup
* Stopping VirtualBox kernel modules * done.
* Uninstalling old VirtualBox DKMS kernel modules * done.
* Trying to register the VirtualBox kernel modules using DKMS
Error! Bad return status for module build on kernel: 2.6.38-10-generic (i686)
Consult the make.log in the build directory
/var/lib/dkms/vboxhost/4.0.0/build/ for more information.
* Failed, trying without DKMS
* Recompiling VirtualBox kernel modules
* Look at /var/log/vbox-install.log to find out what went wrong
I also installed dkms and it is up to date. But still i am facing that error. Here is the vbox-install.log
Uninstalling modules from DKMS
removing old DKMS module vboxhost version 4.0.0
——————————
Deleting module version: 4.0.0
completely from the DKMS tree.
——————————
Done.
Attempting to install using DKMS
Creating symlink /var/lib/dkms/vboxhost/4.0.0/source ->
/usr/src/vboxhost-4.0.0
DKMS: add Completed.
Kernel preparation unnecessary for this kernel. Skipping…
Building module:
cleaning build area….
make KERNELRELEASE=2.6.38-10-generic -C /lib/modules/2.6.38-10-generic/build M=/var/lib/dkms/vboxhost/4.0.0/build….(bad exit status: 2)
0
0
Failed to install using DKMS, attempting to install without
Makefile:185: *** Error: KERN_DIR does not point to a directory. Stop.
Thanks in advance
Thanks for the info.
With Virtual Box 4.1, setting KERN_DIR isn’t sufficient. Your KERN_DIR actually has to be:
## Current running kernel on CentOS and Red Hat (RHEL) ##
KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m`
This isn’t what the devel packages install (at least, this isn’t what I have, and I don’t think I renamed them). The devel pacakge had /usr/src/kernels/2.6.18-194.26.1.el5-x86_64. Once I created KERN_DIR with the uname chant, above, and added a symlink /usr/src/kernels/2.6.18-194.el5-x86_64, the Guest Additions installer was happy. Prior to that, it kept telling me that KERN_DIR was not a directory.
I’m 99% sure I exported KERN_DIR in both scenarios; so it is possible that 4.1.0 VBox doesn’t honor KERN_DIR on CentOS anymore, it generates it internally (and never tells you what it is looking for). Your post saved me the trouble of digging through their shell script. Thanks!
tnk man
thx’s a lot
Hello,
I am having problem installing VB4.1.x on OEL 5.6.
I followed the instructions on this blog to update the packages. ie
—————————————————————————————————-
[root@oraracbox kernels]# yum update kernel kernel-devel kernel-headers
Loaded plugins: rhnplugin, security
This system is not registered with ULN.
ULN support will be disabled.
Skipping security plugin, no data
Setting up Update Process
No Packages marked for Update
[root@oraracbox kernels]#
________________________________________
then I tried to do the installation and this error comes up…
___________________________________________________________________
Makefile:172: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DI
R= and run Make again. Stop.
____________________________________________________________________
so I set my KERN_DIR variable to
[root@oraracbox kernels]# export KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m`
[root@oraracbox kernels]# echo $KERN_DIR
/usr/src/kernels/2.6.32-100.26.2.el5-x86_64
[root@oraracbox kernels]#
when I cd to
[root@oraracbox kernels]# ls -l
total 16
drwxr-xr-x 19 root root 4096 Sep 18 21:25 2.6.18-238.el5-x86_64
drwxr-xr-x 19 root root 4096 Sep 18 21:45 2.6.18-238.el5-xen-x86_64
lrwxrwxrwx 1 root root 25 Sep 18 21:45 2.6.18-238.el5xen-x86_64 -> 2.6.18-238.el5-xen-x86_64
there is directory with 100 in it for my current version of uname -r
that is
[root@oraracbox tmp]# uname -r
2.6.32-100.26.2.el5
Any advice will be much appreciated as I am stuck here….
Hi Rajesh,
Could you post following info:
yum info kernel kernel-devel kernel-headersHi JR A couple of months back i followed ur how-to and installed VB 4.1.
Now i want to upgrade to 4.1.4.
simple “yum update Virtualbox” is enough for this????
And one more issue i am facing is if i keep open VB machine for some time on my centos 5.6 it is having some memory leak.
To get the centos login window i have to kill VB processes running.
If not i cant see any login screen to type my centos password.
Can u please help me on this.
Hi revo,
Updating should be easy…you can use following command if you have VB-4.1 installed:
And if you have VB-4.0 installed then run:
You might to need to run also following command with working KERN_DIR:
Memory leak issues is bit more problematic, but you can try this VirtualBox 4.1.4 version and check what happens with it?
Hi JR
i updated my virtual box using yum update VirtualBox-4.1. And ran setup also.
And this time no memory leaks . It is saying that usb accessibility is not possible. And asking to add user to vboxusers for enabling. How to do this???
Thanks.
Hi revo,
Excellent to hear that memory leaks problems are solved. :)
You can add your user to vboxusers with following command:
Hello JR,
Can’t get the box working. Help needed please…
I have gnome (centos 5.4) running on a clearos system.
can’t install vmbox 3.1 on centos 5.4
[root@system yum.repos.d]# /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel module [ OK ]
Recompiling VirtualBox kernel module [MISLUKT]
(Look at /var/log/vbox-install.log to find out what went wrong)
Makefile:152: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR= and run Make again
Installed Packages
kernel-PAE.i686 2.6.18-194.8.1.v5 installed
kernel-devel.i686 2.6.18-194.8.1.v5 installed
kernel-devel.i686 2.6.18-274.3.1.el5 installed
kernel-headers.i386 2.6.18-274.3.1.el5 installed
php.i386 5.1.6-27.v5.3.1 installed
php-cli.i386 5.1.6-27.v5.3.1 installed
php-common.i386 5.1.6-27.v5.3.1 installed
php-imap.i386 5.1.6-27.v5.3.1 installed
php-kolab.noarch 2.2.0-3.2.v5 installed
php-ldap.i386 5.1.6-27.v5.3.1 installed
php-mbstring.i386 5.1.6-27.v5.3.1 installed
php-mysql.i386 5.1.6-27.v5.3.1 installed
php-pdo.i386 5.1.6-27.v5.3.1 installed
phpMyAdmin.noarch 3.2.3-1.1.v5 installed
phpsysinfo.noarch 2.5.4-4.2.v5 installed
Can you help me?
Hi hoek,
Did you set KERN_DIR variable and exported it?
For Centos 6 depo file (virtualbox.repo from
wget http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo )
Edit it and use this base URL: baseurl=http://download.virtualbox.org/virtualbox/rpm/rhel/$releasever/$basearch
Hi Greg,
Thanks for note.
I actually fixed this part of guide to working directly also with CentOS 6 and Red Hat (RHEL) 6.
Now if you use:
It should work normally with CentOS 6/5.6 and Red Hat (RHEL) 6/5.6. :)
If anyone is interested these are the steps I followed to install VirtualBox 4.1 on a clean installation of Oracle 64bit Enterprise Linux 5.7
– Install Enterprise Linux
– Register on Linux Network
rpm –import /usr/share/rhn/RPM-GPG-KEY
up2date-nox –register
– Register to following channels on Linux Network
Enterprise Linux 5 Add ons (x86_64)
Enterprise Linux 5 Latest (x86_64)
Oracle Software for Enterprise Linux 5 (x86_64)
Oracle Linux 5 Latest (x86_64)
– To install DKMS — Extra Packages for Enterprise Linux (EPEL) v5
rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
yum update
yum install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-devel
yum install dkms
cd /etc/yum.repos.d/
wget http://download.virtualbox.org/virtualbox/rpm/rhel/virtualbox.repo
yum install VirtualBox-4.1
shutdown -r now
– Re-Setup the kernel module by
/etc/init.d/vboxdrv setup — as root
– FINISHED
Hi Mark,
Thank you very much! This is excellent guide, I think I have to improve mine with some things… :)
Well, the guide is excellent, but there is something wrong with the yum guys: ALL THESE commands, steps and decisions should do it automatically by typing “yum install -y virtualbox”! If not, what is the sense of yum??
Just to say thanks! worked great – Fedora 16 – Virtualbox 4.1.6. Reboot is a must people!! mine only sorted the kernel after that! Cheers again!