Live data from Hacker News

Ditching Vagrant: VMs with KVM and Virsh on Debian

benjamintoll.com

11–20 of 49 posts

Re: Ditching Vagrant: VMs with KVM and Virsh on Debian

#11

There used to be virt-manager Wonder if it’s still around ? Hope it’s doing well !

Unfortunately it still exists. Virt manager drives me crazy because it hides the VM files in its own directory with permissions that aren't yours forcing you to use sudo to manually manage your own fucking vm files. Creating a new VM? You're forced to pick an OS by typing the name of your OS into a search box which is tedious and doesnt give you an option for generic x86 machine. I hate it with a burning passion and…

> Virt manager drives me crazy because it hides the VM files in its own directory with permissions that aren't yours forcing you to use sudo to manually manage your own fucking vm files.

I just checked my `~/.local/share/libvirt/`. It doesn't do this for me, and I don't think it ever has.

I do remember having to set this up at some point. Looks like this is it:

https://unix.stackexchange.com/questions/799034/whats-the-di...

There are some limits around network ports in User Sessions, but it should suffice for anything you'd use Vagrant for.

> Creating a new VM? You're forced to pick an OS by typing the name of your OS into a search box which is tedious and doesnt give you an option for generic x86 machine.

...There is though? It's in the dropdown under "Generic or unknown OS. Usage is not recommended (generic)". Here it is in the code if you don't believe me:

https://github.com/virt-manager/virt-manager/blob/c3df2ba/vi...

And a random tutorial which makes use of it:

https://cyberlab.pacific.edu/courses/comp178/resources/virtu...

Re: Ditching Vagrant: VMs with KVM and Virsh on Debian

#12

There used to be virt-manager Wonder if it’s still around ? Hope it’s doing well !

Until recently, I used it routinely for VMs, and it worked solidly and reliably. There is a ZFS storage backend as well, always nice to see since I've loved to use zvols for VMs, even when I did VirtualBox on OpenIndiana back before ZFS on Linux was viable.

But I found that Proxmox fit my needs much better than wrestling vanilla Ubuntu or Debian into a VM server, particularly for things like backup/restore and instrumentation, or setting up a bridge on a desktop-based installation. Since both are based on QEMU/KVM, it wasn't too hard to move my VMs (one thing you might need to look out for is changing network interface names).

Re: Ditching Vagrant: VMs with KVM and Virsh on Debian

#13

There used to be virt-manager Wonder if it’s still around ? Hope it’s doing well !

I still use it for home projects and it's great!

Little wonky to get the config files all setup for a VM but LLMs make that a breeze these days.

Re: Ditching Vagrant: VMs with KVM and Virsh on Debian

#14
post #9

There used to be virt-manager Wonder if it’s still around ? Hope it’s doing well !

"around" is the best way to describe it; the libvirt/virt-manager ecosystem isn't dead, but redhat killing off ovirt/rhev support drained a lot of resources out of it. And for some bizarre reason people decided that the much less mature (both organizationally and technologically) proxmox VE is the best thing since sliced bread, so everyone who does care about linux virtualization is now trying to hammer some homelabb…

Red Hat is still using and developing libvirt (though the user facing layer is Kubevirt instead of oVirt) and virt-install, and even though virt-manager is not growing new features libvirt takes backwards compatibility extremely seriously, so new libvirt works with relatively old virt-manager.

Re: Ditching Vagrant: VMs with KVM and Virsh on Debian

#15

Earlier quoted context omitted.

Unfortunately it still exists. Virt manager drives me crazy because it hides the VM files in its own directory with permissions that aren't yours forcing you to use sudo to manually manage your own fucking vm files. Creating a new VM? You're forced to pick an OS by typing the name of your OS into a search box which is tedious and doesnt give you an option for generic x86 machine. I hate it with a burning passion and…

> Virt manager drives me crazy because it hides the VM files in its own directory with permissions that aren't yours forcing you to use sudo to manually manage your own fucking vm files. I just checked my `~/.local/share/libvirt/`. It doesn't do this for me, and I don't think it ever has. I do remember having to set this up at some point. Looks like this is it: https://unix.stackexchange.com/questions/799034/whats-th…

There are two ways to run the Libvirt daemon, which are unprivileged and privileged aka system. You are using unprivileged mode, the parent is using system mode which is more powerful and provides better isolation but does hide stuff in /var.

For example, running QEMU as its own user and using PCI passthrough is only possible with the system daemon.

You also need the system daemon to set up bridged networking, though the unprivileged daemon can use it through a setuid helper.

Re: Ditching Vagrant: VMs with KVM and Virsh on Debian

#16

There used to be virt-manager Wonder if it’s still around ? Hope it’s doing well !

It's usable (?) as a toy: numerous gui inconsistencies and lack of security isolation [0].

Can't say whether the of lack funding (move to Cockpit from Red Hat) is the reason, or maintainer is just an obstructionist (strictest feature policy).

[0] https://github.com/virt-manager/virt-manager/issues/358

Re: Ditching Vagrant: VMs with KVM and Virsh on Debian

#17
virt-builder is an alternative to installing a guest OS from scratch. It has a selection of popular guest OSes template images that you can quickly install non-interactively.

It's convenient when you don't want to manually install a guest and also don't want to figure out preseed/kickstart/etc.

It makes creating new KVM guests easier and has handy features like the ability to copy in ssh keys so you can connect to the guest right away.

Post reply on HN