Ask HN: Why is virtualization still not solved?
16 points by prmph a day ago
16 points by prmph a day ago
It's 2025, and virtualization is still a headache, even for casual use.
I use a MacBook Air M1 as my dev laptop, and I just wanted to have a reproducible dev environment running Debian.
My options: use devcontainer, or use a VM on Virtualbox, VMWare, Parallels, UTM, etc.
VSCode & Typescript gets messed up every now and then, such that they don't work and I simply can't continue with them. Not sure why, but I think there are weird internal bugs in those that surface whenever there is some special combination of circumstances on my machine. With devcontainer I think VSCode still runs directly on my machine but connects to the container, so this is nto a solution for me, I need a real VM.
So I try VirtualBox first. After spending hours installing Debian on a VM and getting it running nicely, within a short time the VM slows to a crawl. Nothing I do reliably fixes this. I also cannto get the display resolution to behave properly. I give up on VirtualBox, again (I keep trying this every few years forgetting why I don't use VirtualBox)
Next, I want to try VMWare, only to find out it is sold to Broadcom, and when I follow the link to their page, I'm supposed to log in to download, and yet I see no way to register. Oh well.
Next, I try Parallels. After getting a Debian VM running on it, I marvel at how smoothly it works. I'm in the trial, but I'm not going to have a problem paying up if everything goes on well. Alas, it was too good to be true. I start to to have random loss of internet connectivity (weirdly affecting the terminal only) in the VM. I see that the default networking mode is shared networking. I read guides online suggesting to switch to bridged networking. After spending oodles of time setting up the firewall and other security configuration on the VM and switching to bridged networking, I'm still having intermittent connectivity issues. it seems they are even worse now. Suddenly I remember again why I don't have a Parallels subscription after all these years.
Frustrated, I finally give up. I ruefully remember that UTM also has similar performance and screen display problems as VirtualBox.
So what options are left? I can't really physically install a dual-boot Linux on my Macbook (Asahi notwithstanding, since I only want Debian). Maybe I could sign up for a cloud VPS and use that. Or just buy new AMD mini PCs and run Debian on those. Either way, it's clear the virtualization story, after decades of supposed tech advancement, is still a bitter one.
Sounds like an Apple problem? Virtualization is definitely solved for your use case on Linux. Personally I use virt-manager for the UI but its all qemu underneath AFAIK. This works but qemu definitely isn't fast like VMWare or VirtualBox IME. It works fine for my HomeAssistant. qemu-kvm woth cpu=host is definitely as fast as it can be, at least on intel platforms with vt-d/vt-x. It is an Apple problem. Virtualization has been solved for good, even the cheapest consumer hardware has virtualization support since at least a decade by now and I sometimes run virtual machines on a 4GB netbook with an Atom processor just for fun. I am running 100% automatically deployed/configured Debian desktops on Apple hardware for several years now, Intel and M1 CPUs. (100% reproducible is another level and another story). Right now and for most of the past years I am running VMWare Fusion, which works with the features I need as long as you don't update macOS immediately after a new major revision was released. (Apple messing up internal APIs nearly every time.) Sometimes in the past I also used the QEMU version provided by macPorts, and the only issue I had was with my non English keyboard, if you use a US keyboard layout you shouldn't have any issues at all. Still, I am surprised, you seem to imply that you need to provision a new VM because of trouble with TypeScript/VSCode? Not sure what you are doing, or what plugins in VSCode you are running, but that I have to provision an entirely new VM to solve such kind of problems never happened to me and I haven't heard about that in my environment (big company, quite a lot of VSCode and TypeScript users). The problem is that the whole virtualization situation was left as an afterthought in the Apple ecosystem, and it got worse during the Apple Silicon transition years. Just now things are starting to catch up, but there's still a wide gap in features; Apple Virtualization Framework is still very limited. And a personal limitation I hit recently, no USB4/Thunderbolt passthrough anywhere, not in UTM (which uses AVF), not in VMWare either. Also remember the final Apple Silicon version of VMWare supporting M1/M2 wasn't available until November 2022 (it was a tech preview before), while all the Broadcom situation was ensuing. And I think only as of 2024 it runs smoothly. So far it's still the most reliable for desktop Linux VMs for me. Windows 11 for ARM runs very well too, and it does x86 emulation transparently, even 2010s games run well. The uncomfortable reason is, despite WWDC hooplah and ostensible dev support, Apple looks down on developers as annoyances because designers, rich people, and celebrities are their north star... because it's all about the elite culture and lifestyle. I see. But how exactly do I get VMWare now if I can't log into Broadcom's website? FWIW, I've used VMWare Fusion on Mac OS for years (and their Workstation product on Linux/Windows since 1999). It has worked well for me so far. VirtualBox used to be not great on MacOS with multiple CPUs and lots of interrupts - I noticed problems when moving from a Mac laptop with a spinning HDD to NVMe SSDs. The slow inter-processor interrupts (IPIs) and some related contention caused concurrent IOs to get very slow with fast SSDs with VirtualBox (back when still running on an Intel Mac with VMWare kernel module). In fact, I could get more IOPS out of the VM with fio when giving just 1-2 vCPUs to the VM, vs 4-8 vCPUs. I haven't tested VirtuaBox on latest Mac versions as I'm happy with VMWare Fusion (also on ARM M1/M2 machines). The product is still good, regardless of Broadcom's business shenanigans. Edit: If Parallels works for you, but only the SSH terminal sessions get stuck, maybe the "shared network" connection drops your connections for some reason. Before diving too deep into troubleshooting this across layers, you could try out the usual suspects workaround, setting SSH TCP keepalive. I have this for some connections in my ~/.ssh/config file: TCPKeepalive yes ServerAliveInterval 30 Are you looking to run Debian desktop or server? Have you tried using Colima [1] with a Docker volume, instead of all those heavyweight tools? Just a Debian desktop. I think I need a full VM, since I am working on stuff that require a fully isolated environment. Maybe try the open source qemu support for the macOS Hypervisor.framework (HVF)? https://www.arthurkoziel.com/qemu-ubuntu-20-04/
https://www.arthurkoziel.com/running-virt-manager-and-libvir... Qubes (Xen). It's poorly-documented and doesn't offer a simple-enough, useful devX/UX. This would be the best starting point. Apple fails to offer true, useful nested virtualization. Canonical (Ubuntu) is run by unreasonable people. VMware ESXi... for servers and Brocade sucks. You didn’t explain why you wanted to use debian, you don’t have to, but there are a lot of x86 based laptops out there that will run various linux distros so I wonder why you’re on a Mac to start with? Employer choice and not yours? You mention Typescript which I’ll assume means some sort of web development, one thing to maybe consider is looking at https://omakub.org/ for inspiration on hardware choices and a setup. I don’t use it but was looking at it recently out of curiousity (I do Rails so thats how I’m aware of DHH and him leaving Apple HW). I use a MacBook Air M1 as my dev laptop, and I just wanted to have a reproducible dev environment running Debian. Computers are cattle not pets and the simplest technical solution is a laptop that supports Debian. A Thinkpad for example. Removing a dependency on VM’s would be a reasonable engineering strategy. podman and Docker run just fine on arm macOS. Both also support multiple architectures through emulation. Docker supports: arm64 amd64 amd64/v2 riscv64 ppc64le s390x and 386. Also, dev containers should == server containers. This is the proper way to develop, and it's entirely unreasonable and impractical to also foist a server OS as a developer laptop OS. Use the most useful, comfortable, and practical developer desktop OS... which, sadly, is rarely Linux even these days because app support and OS usability still isn't at parity with the $$ ones post-Canonical. Invariably, it's Mac or Windows. If someone also wishes to make their lives more difficult (or perhaps easier), then all power to them to run a Linux distro or FreeBSD. podman and Docker run just fine on arm macOS If virtualization is solved, then the OP's question is moot. However based on the question, the OP does not appear to think virtualization is solved yet. On Windows I've had good experiences running Linux under virtualization. Right now my RSS reader and Image sorter are running under WSL2 with no problems. I used to use VirtualBox and it worked pretty well.
ac29 - a day ago
metadat - a day ago
znpy - 21 hours ago
CopyOnWrite - 17 hours ago
mickelsen - a day ago
burnt-resistor - 21 hours ago
prmph - 21 hours ago
tanelpoder - a day ago
ValentineC - a day ago
prmph - 21 hours ago
pabs3 - a day ago
burnt-resistor - 21 hours ago
matt_s - a day ago
brudgers - a day ago
burnt-resistor - 21 hours ago
brudgers - 10 hours ago
PaulHoule - a day ago