Live data from Hacker News

Running GUI Linux in a virtual machine on a Mac

developer.apple.com

171–180 of 206 posts

Re: Running GUI Linux in a virtual machine on a Mac

#171

Earlier quoted context omitted.

I'm not sure what you think Docker on a Mac does. Docker is a Linux-specific piece of software, and the only way to use it within macOS is to run a Linux virtual machine, with Docker running inside the Linux VM. If the containers you want to run with Docker are x86 software, that Linux VM either needs to be an x86 Linux distro running in qemu emulation of a full x86 machine, or an ARM Linux distro using the new (not…

> Docker is a Linux-specific piece of software, and the only way to use it within macOS is to run a Linux virtual machine, with Docker running inside the Linux VM. That is entirely untrue: https://docs.docker.com/desktop/install/mac-install/ Hell, it’s even on Windows.

In all cases, the Docker daemon is running under Linux. The Mac and Windows versions are merely bundling up a Linux VM containing Docker with a frontend that's as transparent as possible, but still with Linux as a hard requirement.

Pretending that the Mac and Windows versions somehow aren't using Linux VMs behind the scenes is of no use to anyone. It's a convenience for users when they can get by with ignoring the VM layer, but a detriment when we see people start talking as though Docker for Mac is functionally different from a Linux VM running Docker, and start assuming that enhancements to running Linux VMs under macOS would be inapplicable to and incompatible with "Docker for Mac".

Re: Running GUI Linux in a virtual machine on a Mac

#172

Earlier quoted context omitted.

> You can, but running Linux with a graphical desktop on VirtualBox under MacOS has become extremely sluggish in my experience. Huh? It's actually faster than ever, and near native experience. And the post is not about "how to run" a virtual machine as an end user or dev (for that the way the parent describes is still the suggested way). It's about how to program running it under the hood if you're a developer who wa…

> It's about how to program running it under the hood if you're a developer who wants to develop something like a program that manages virtual machines Has somebody already done that perhaps? Is there a reasonable alternative to VirtualBox/WMWare using the optimal way to run a VM on a Mac? I don't mind paying if it's worth it. I have zero experience of Mac development but I am going to need to run Windows 7 (to use I…

> Has somebody already done that perhaps?

Yes. And there have been several examples of small or independent developers cobbling together VM applications based on Apple’s frameworks in the last year or so. I do my know how many will actually survive but there is quite a bit of developer interest.

> Is there a reasonable alternative to VirtualBox/WMWare using the optimal way to run a VM on a Mac? I don't mind paying if it's worth it.

I don’t know about VMWare, but Parallels does this (for money, I am not a fan of their subscription model). AFAIK the best free equivalent is UTM, which can use either Apple’s frameworks or QEMU: https://mac.getutm.app/ .

> I have zero experience of Mac development but I am going to need to run Windows 7 (to use IE6 with old crypto to access an outdated state-ran system) on an M2 MacBook next week. What's the best way to achieve that?

I would try UTM, personally.

Re: Running GUI Linux in a virtual machine on a Mac

#173

Earlier quoted context omitted.

There is already much user demand & vendor support for running virtual machines (including for Windows) on Apple hardware, through Parallels, VMWare and Qemu. Like there are options for containers, it is great to have another option for virtual machines.

Options are good. But the way Apple operates to exert control and cripples softwares that don't align with their goals, don't be surprised if Apple suddenly forces developers to only use their virtualisation API on macOS, just like they did for application firewalls (that are no longer allowed to have their own custom kernel extensions for "security" and "stability"). They are slowly squeezing macOS to make it more a…

> that are no longer allowed to have their own custom kernel extensions for "security" and "stability"

You keep implying that there are ulterior motives without a shred of justification. Why do you think that? What power do they get by doing this?

Also, it does not prevent things like Little Snitch or the various Objective See tools from being developed. There are no fewer firewall apps than there used to be. There are no fewer virtualisation applications either.

What you don’t get is that they started from the position that kernel extensions were an attack vector and a factor of instability. Then, they started addressing each use case for kernel extensions by providing user-level facilities. You probably set the cursor at a different location on the security spectrum, but it does not mean that you are any more right than they are.

> They are slowly squeezing macOS to make it more and more like ios.

Some people have been making that tired claim for more than a decade now. You’be had year to see how it works and where they are going, and it keeps not happening. Why do you think this is more credible now?

Re: Running GUI Linux in a virtual machine on a Mac

#174

Earlier quoted context omitted.

They had the opportunity to do this when introducing the M-series Macs, because under the hood those work very similarly to iPhones and iPads. They could've done a direct copy-paste from the iDevice boot process and called it a day, but they didn't… they went out of their way to develop support for booting third-party operating systems, complete with a path for painless long term support with the flexibility of allow…

> They had the opportunity to do this when introducing the M-series Macs No, they didn't because a Mac computer that is fully locked like the iDevices wouldn't have been popular and would have meant a lot of bad publicity for the M1 mac desktops. Apple Silicon M1 / M2 macs can only run crippled versions of other OSes and macOS is being slowly converted to be more and more like ios. It's the Boiling Frog strategy - ht…

> No, they didn't because a Mac computer that is fully locked like the iDevices wouldn't have been popular and would have meant a lot of bad publicity for the M1 mac desktops.

Approximately nobody would have passed on a Mac because it could not boot Windows or Linux. This has been more or less the state of Macs since the release of the first M1 devices, and they sell rather well. There is demonstrably quite a lot of interest for these devices running macOS.

> Apple Silicon M1 / M2 macs can only run crippled versions of other OSes

How so? What do they do to cripple other OSes?

> It's the Boiling Frog strategy

Quoting Wikipedia for common phrases does not make you more credible. Again, people have been saying that for more than a decade. It is not inconceivable that it could happen in the future, but then anything could happen in the future. And in the meantime you still sound like a broken clock.

> to ensure that they don't scare away their users.

The whole history of iOS demonstrates the opposite. As said in the parent comment. They’ve had opportunities to actually go to that direction. Nobody was expecting third-party OS support.

Re: Running GUI Linux in a virtual machine on a Mac

#177
post #130

Earlier quoted context omitted.

> I feel like I pretty much have full control over my Mac laptop. https://news.ycombinator.com/item?id=25074959

Oh please. You are quoting an issue that happened two years ago and Apple has already acknowledged that their algorithms were crappy and promised to reengineer this stuff. This is like claiming that Linux does not allow you to install software because a repository happens to be down.

So where is the redesign? This is like saying that a repository is down for two years, but it's fine, since they promised to fix that. Also, it's much worse, because Apple knows every app you run, including, e.g., Tor Browser. Do you think it's good for your privacy? Can you yourself fix that on "your" computer, which you "control"?

Re: Running GUI Linux in a virtual machine on a Mac

#178

Earlier quoted context omitted.

> Docker is a Linux-specific piece of software, and the only way to use it within macOS is to run a Linux virtual machine, with Docker running inside the Linux VM. That is entirely untrue: https://docs.docker.com/desktop/install/mac-install/ Hell, it’s even on Windows.

In all cases, the Docker daemon is running under Linux. The Mac and Windows versions are merely bundling up a Linux VM containing Docker with a frontend that's as transparent as possible, but still with Linux as a hard requirement. Pretending that the Mac and Windows versions somehow aren't using Linux VMs behind the scenes is of no use to anyone. It's a convenience for users when they can get by with ignoring the VM…

> In all cases, the Docker daemon is running under Linux. The Mac and Windows versions are merely bundling up a Linux VM containing Docker with a frontend that's as transparent as possible, but still with Linux as a hard requirement.

I really doubt that's the case if you run native Windows containers on Windows.

Re: Running GUI Linux in a virtual machine on a Mac

#179
post #122

Earlier quoted context omitted.

For those not in tune with virtualbox, this beta lets you run 32-bit x86 guests on aarch64 macOS

Sadly it does not appear to work that well.. Quote: There has been no port to M1/M2. All there has been is early work that does nothing useful but somehow escaped the stables. You can safely forget all about it for now. [0] https://forums.virtualbox.org/viewtopic.php?f=15&t=106919

Yeah it’s a shame still looks promising.

Re: Running GUI Linux in a virtual machine on a Mac

#180

What is the current state of vagrant on Mac Virtualization? Vagrant is the thing that I really miss on ARM.

Get a Parallels license and use it as the vagrant provider. That still seems to be the only real option. https://www.parallels.com/
Post reply on HN