Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I've install virtualbox inside an lxc container. However when I try to start a VM I get the message:

kernel driver not accessible (rc=1909) ....permission problem with /dev/vboxdrv.

This obviously looks like a predictable security issue.

Does anyone know how I can grant permission to the container to access this device driver: '/dev/vboxdrv'?

Any help or pointers greatly appreciated.

share|improve this question

migrated from serverfault.com Jul 6 '13 at 18:29

This question came from our site for professional system and network administrators.

2 Answers 2

The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a permission problem with /dev/vboxdrv. Re-setup the kernel module by executing

 '/etc/init.d/vboxdrv setup'

as root. Users of Ubuntu or Fedora should install the DKMS package at first. This package keeps track of Linux kernel changes and recompiles the vboxdrv kernel module if necessary.

share|improve this answer
    
This is just a quote from the error message. The driver is loaded but the container doesn't have permission to access it. As per the error response. My question was: how does one grant permission to processes within a container to access kernel devices?? How do I solve the permissions problem? –  user108168 Jul 6 '13 at 15:59

You need to have /dev/vboxdrv owned by group "vboxuser" and user starting the container in that group. Add the user to the group then ensure there's group permissions (i.e chmod 660 /dev/vboxdrv).

share|improve this answer
    
Hi Nathan C. Thanks for your response. Where am I doing this; in the host environment or the container? –  user108168 Jul 6 '13 at 16:34
    
The host assuming the kernel drivers are installed there (which they should since LXC relies on the host kernel). –  Nathan C Jul 6 '13 at 16:35
    
Hi Nathan C Thanks for the clarification. The device /dev/vboxdrv is owned by root and I'm starting the container as root. I was running virtualbox as another user within the container but tried running it as root. I also chmoded the device to set the group to vboxusers and the permissions to 660. I'm still getting the error. Everything works fine on the host for both root and non-root users. Do I not have to put a setting in the lxc config file to grant permissions to the container?? That's what I assumed but don't know what they are. Thanks for your help. –  user108168 Jul 6 '13 at 17:32

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.