[Nix-dev] How to install in NixOS in a KVM virtual machine?

Marc Weber marco-oweber at gmx.de
Sat Feb 8 13:27:57 CET 2014


Qemu is a common backend for KVM, isn't it?

There you can attach disks created by qemu-img.
Then you can attach cdroms. Eg

qemu-system-... -hda img  -cdrom image.iso 

Then you can install as usual.

The -hda might be too simple, nixpkgs/nixos has some tests illustrating
how to attach (so that grub finds disk position - eg have a look at
qemu-vm.nix

kvm or VirtualBox? Depends on the features you want. VirtualBox
traditionally has better graphic support and special drivers allowing to
share clipboard, resize screen and the like (no idea whether kvm
followed this). Thus if you care about gui VirtualBox could be the
better option for that reason (You cannot have kvm and VirtualBox at the
same time AFAIK - maybe this changed).

Except the default installer iso you can try minimnal install archives
etc, see "installing nixos @ XY" guides at the wiki, they are official.

I have inofficial minimal install archives, they could be easier to use
but might be broken at the moment (and less well tested).

At least this mail should help you find out what you're missing exactly.

Marc Weber


More information about the nix-dev mailing list