[Nix-dev] VirtualBox won't start VMs after kernel update

Matthias Beyer mail at beyermatthias.de
Thu Apr 23 16:42:32 CEST 2015


On 22-04-2015 02:09:43, phreedom at yandex.ru wrote:
> On Tuesday, April 21, 2015 22:30:54 Matthias Beyer wrote:
> > (@ phreedom: You forgot to CC the list, so I re-send with inline
> > reply, so others can see your message text as well):
> > 
> > On 21-04-2015 22:19:07, phreedom at yandex.ru wrote:
> > > On Tuesday, April 21, 2015 17:39:58 Matthias Beyer wrote:
> > > > I did a kernel update recently. I run 3.18.7 now. I just re-installed
> > > > VirtualBox in my User Env (I had to build it, actually - why?) with
> > > > 
> > > >     `nix-env -i virtualbox -j 8 --cores 8`
> > > > 
> > > > but I still cannot start my VM. It tells me to
> > > > 
> > > >     `/etc/init.d/vboxdrv setup`
> > > > 
> > > > but of course, this is not possible :-)
> > > > 
> > > > What do I do?
> > > 
> > > I'm very surprised that it ever worked like this. VirtualBox needs kernel
> > > modules installed and you can't install them via nix-env at all.
> > 
> > I have services.virtualbox.enable = true; in my configuration.nix, so
> > this should pull the configuration you listed below into my
> > configuration as well, shouldn't it?
> > 
> > > boot.extraModulePackages = [ config.boot.kernelPackages.virtualbox ];
> > > environment.systemPackages = [ config.boot.kernelPackages.virtualbox ];
> > 
> > I see my problem now, as I installed virtualbox again as a user, which
> > cannot work, of course, as the kernel needs to be modified. Put then,
> > I wonder why my kernel update did not pull a new virtualbox into my
> > machine setup?
> > 
> > > You need to load modules: vboxdrv, vboxnetadp, vboxnetflt
> > > And make sure the user you run as has access to /dev/vbox* devices.
> > 
> > Shouldn't Nix keep track of these points automatically?
> 
> I didn't notice someone already made a nice module for virtualbox, but it's 
> called services.virtualboxHost, and enabling it does seem to make everything 
> just work, so uninstalling virtualbox via nix-env is what you need to use the 
> virtualbox installed via configuration.nix

It doesn't I actually reloaded the vboxdrv kernel module by hand
(using rmmod and modprobe), but virtualbox still won't start my VM.

-- 
Mit freundlichen Grüßen,
Kind regards,
Matthias Beyer

Proudly sent with mutt.
Happily signed with gnupg.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
Url : http://lists.science.uu.nl/pipermail/nix-dev/attachments/20150423/ac615d51/attachment.bin 


More information about the nix-dev mailing list