Remix.run Logo
Apple Silicon and Virtual Machines: Beating the 2 VM Limit (2023)(khronokernel.com)
109 points by krackers 3 hours ago | 53 comments
RestartKernel 3 hours ago | parent | next [-]

This is a really cool article, but the existence of such an arbitrary limit on any serious development platform is weird.

tempest_ 3 hours ago | parent [-]

Has apple been a serious development platform in the last 20 years?

I know a lot of devs like apple hardware because it is premium but OSX has always been "almost linux" controlled by a company that cares more about itunes then it does the people using their hardware to develop.

jaredklewis an hour ago | parent | next [-]

At least 9 out of every 10 software engineers I know does all their development on a mac. Because this sample is from my experience, it’s skewed to startups and tech companies. For sure, lots of devs outside those areas, but tech companies are a big chunk of the world’s developers.

So yea I would say Apple is a “serious development platform” just given how much it dominates software development in the tech sector in the US.

OptionOfT an hour ago | parent | next [-]

I have the feeling a lot of people take Macs because the other option is a locked down Windows, and Linux is not offered.

manithree 35 minutes ago | parent | next [-]

This. I ran Linux at work until last year, when it was finally disallowed. I went with locked-down Mac over locked-down Windows.

hparadiz an hour ago | parent | prev [-]

The hardware for a Linux laptop right now is not great. Especially for an arm64 machine. Even if the hardware is good the chassis and everything else is typically plastic and shitty.

c0balt 9 minutes ago | parent [-]

That is a surprising sentiment. Most dell and Lenovo laptops work just fine and are usually of reasonably good build quality (non-plastic chassis etc.).

arm64 is however mostly bad. The only real contender for Linux laptops (outside of asahi) was Snapdragon's chips but the HW support there was lacking iirc.

gambiting an hour ago | parent | prev [-]

>>At least 9 out of every 10 software engineers I know does all their development on a mac

I work in video games, you know, industry larger than films - 10 out of 10 devs I know are on Windows. I have a work issued Mac just to do some iOS dev and I honestly don't understand how anyone can use it day to day as their main dev machine, it's just so restrictive in what the OS allows you to do.

st3fan an hour ago | parent [-]

Weird .. macOS is still completely open is my experience. Can you give an example?

gambiting an hour ago | parent [-]

I compile a tool we use, send it to another developer, they can't open it without going through system settings because the OS thinks it's unsafe. There is no blanket easy way to disable this behaviour.

We also inject custom dlibs into clang during compilation and starting with Tahoe that started to fail - we discovered that it's because of SIP(system integrity protection). We reached out to apple, got the answer that "we will not discuss any functionality related to operation of SIP". Great. So now we either have to disable SIP on every development machine(which IT is very unhappy about) or re-sign the clang executable with our own dev key so that the OS leaves us alone.

10000truths 41 minutes ago | parent | next [-]

If SIP is kicking in, it sounds like you're using the clang that comes with Apple's developer tools. Does this same issue occur with clang sourced from homebrew, or from LLVM's own binary releases?

fragmede 5 minutes ago | parent | prev [-]

If it's being sent to another developer then asking them to run xattr -rd com.apple.quarantine on the file so they can run it doesn't seem insurmountable. I agree that it's a non-starter to ask marketing or sales to do that, but developers can manage. Having to sign and then upload the binary to Apple to notarize is also annoying but you put it in a script and go about your day.

But Apple being "completely open", it is not.

amelius 2 hours ago | parent | prev | next [-]

It is a weird situation. Apple products are consumer products but they make us use them as development hardware because there is no other way to make software for those products.

thomascountz 2 hours ago | parent | prev | next [-]

Anything being developed for the Apple ecosystem requires use of the Apple development platform. Maybe the scope could be called "unserious," but the scale cannot be ignored.

tempest_ 2 hours ago | parent [-]

I am aware.

However having used Xcode at some point 10 years ago my belief is that the app ecosystem exists in spite of that and that people would never choose this given the choice.

jonhohle 2 hours ago | parent | prev [-]

For me at least, not being Linux is a feature. Linux has always been “almost Unix” to the point where now it has become its own thing for better or worse. OS X was never trying to be Linux. It would be better if we still had a few more commercial POSIX implementations.

tempest_ 2 hours ago | parent [-]

That is fair but in my experience most devs are targeting linux servers not BSD(or any other flavour) which is helped by OSX. If OSX was linux derived it would suit them just as well.

edit: I suppose I should also note the vast majority of people developing on mac books (in my experience anyway) are actually targeting chrome.

jonhohle 2 hours ago | parent | next [-]

Heterogeneity is the feature. The Linux ecosystem is better off for it (systemd, Wayland, dconf, epoll, inotify are all based on ideas that were in OS X first) and not being beholden to Linux is a competitive advantage for Apple everyone wins.

RestartKernel 2 hours ago | parent | prev [-]

> I suppose I should also note the vast majority of people developing on mac books (in my experience anyway) are actually targeting chrome.

Point taken. Most developers probably make do with Linux containers rather than MacOS VMs.

kylec 3 hours ago | parent | prev | next [-]

This is a very silly restriction, at least to apply uniformly to all Macs. I think if you buy a more powerful Mac they should let you virtualize more Mac instances. Like an M5 maybe limit to 2, but maybe let an M5 Pro do 4 and an M5 Max do 8 or something.

benoau 2 hours ago | parent | next [-]

Why should they impose a limit at all? Your hardware is a natural limit, you'll stop of your own accord when you reach its thresholds.

naikrovek 2 hours ago | parent [-]

They are likely scared of people who would run MacOS virtual desktop farms, without also buying an appropriate number of Apple machines.

That’s what I would be worried about if my primary source of income was hardware sales.

ryandrake 2 hours ago | parent | next [-]

Apple had to be dragged kicking and screaming into the world of virtualization and the idea of macOS running on anything besides "metal built by Apple." They've been pretty clear for decades that they only care about customers who buy Apple aluminum and silicon.

woodson an hour ago | parent [-]

Well, but their customers are those that buy Apple hardware.

moondev an hour ago | parent | prev [-]

Imagine buying a mac studio with 500+ GB of memory and being limited to 2 vms.

bdcravens 40 minutes ago | parent | prev | next [-]

The limit isn't really a resource issue, since you can run pretty much an "unlimited" number of non-Mac VMs. I suspect it's more of a business decision, such as preventing people from setting up shop as a low-cost Mac VPS provider.

whatsupdog an hour ago | parent | prev [-]

"Can you please apply soothing balm after you beat me?" That is what you sound like.

Khalid_nowaf 3 hours ago | parent | prev | next [-]

I’m very curious, why did Apple put such a limitation?

ralph84 an hour ago | parent | next [-]

Because their business model is to sell tightly integrated hardware and software as a package. The hardware sales fund the software development. They don't want people who haven't bought the hardware using the software.

moondev an hour ago | parent | next [-]

The VM limit only applies to the number of macOS VMs launched from macOS itself.

My 2018 mac mini officially supports VMware ESXi to be installed directly on the hardware and virtualize any number of macOS machines

Funny enough I can even launch more than 2 macOS vms on my framework chromebook with qemu + KVM from the integrated Linux terminal.

benoau an hour ago | parent | prev [-]

Yeah but the "hardware" in that sense is almost entirely iPhone and iPhone-adjacent, Mac is a trailing 4th- or 5th-place line of business... maybe 6th.

cluckindan 3 hours ago | parent | prev [-]

Probably to prevent a single hardware system from being used to run an online identity farm.

mschuster91 2 hours ago | parent [-]

Doesn't make too much sense, the VMs don't get unique hardware identifiers that one could (ab)use for spamming iMessage.

peyton an hour ago | parent [-]

That kind of tracks as the source of the concern. My first thought was it’d be something IDMS-related as well. I don’t know enough about that system to pinpoint exactly what.

czk 3 hours ago | parent | prev | next [-]

starting with M3+ you can use Hypervisor.framework/Virtualization.framework to spin up nested VMs.

it would be amusing if that bypassed the limit.

rayiner an hour ago | parent | prev | next [-]

It’s crazy that you can compile a custom kernel and it’ll boot and the GUI will run.

ab_testing 2 hours ago | parent | prev | next [-]

Very funny to see HN hate on Microsoft and Google but then love a company where they cannot even run an app on their mobile platform without Apple's permission or only a certain number of VMs on the hardware they own .

monocularvision 44 minutes ago | parent | next [-]

Someday I may be able to retire this link, but today is not that day: https://en.wiktionary.org/wiki/Goomba_fallacy

toobulkeh 26 minutes ago | parent [-]

I’ve been looking for this for forever. Finally, the right label.

matheusmoreira an hour ago | parent | prev | next [-]

HN is not one person. I'm very happy to hate on all of them. I see what you mean though. I've given up on getting normal people to care, but seeing programmers who are absolutely smart enough to run their own Linux system on computers they actually own actively choose not to do so is very disconcerting.

AussieWog93 25 minutes ago | parent [-]

>seeing programmers who are absolutely smart enough to run their own Linux system on computers they actually own actively choose not to do so is very disconcerting.

I run macOS because Apple understands that QA testing is something of actual importance, and designing yet another package manager is not.

I do spin up Linux every now and again to see if it's good yet, and always walk away.

Why do documents print at ~50dpi on my network printer?

Why does the system simply not wake up ~20% of the time when I open my laptop's lid?

Why do I have to unplug and reconnect my USB WiFi Dongle every hour or so when the internet randomly drops out?

Why does the system stop recognising my USB SD Card reader occasionally, forcing me to hard reboot the system?

Why is the audio distorted over HDMI when I enable HDR?

Why does Kodi only detect a refresh rate of 30Hz when the system itself has no issues seeing that the monitor is 60Hz?

All of these are real problems that real users have had, but instead of solving them the Linux development community instead chooses to devote their time and resources navel gazing about systemd alternatives or creating a fragile AUR package for software that already has a sensible and officially supported distribution method.

matheusmoreira 16 minutes ago | parent [-]

TL;DR you sacrificed your freedom for convenience, you think quality assurance is worth being at Apple's mercy, you signed away the keys to "your" machine so they can "manage" it for you along with the rest of your life.

Meanwhile I'm running about a dozen of development virtual machines right now. I'm limited only by the amount of RAM my computer has. It never even occurred to me that some gigacorporation out there would have thought to limit the VMs their own users can spawn. Every day, they reach a new low.

ericmay 10 minutes ago | parent [-]

On the other hand I’m very conveniently enjoying my experience, I don’t have to waste time screwing with stuff I have no interest in screwing with - like the OP’s examples, and if I want to run Linux I’ll just install it and do what I want or rent out some compute time somewhere.

Besides, you can buy a Mac and do whatever you want and go buy a bunch of off the shelf components to do whatever hobby stuff you want to do too.

Freedom, perhaps, starts with not making up and applying limitations on yourself.

dghlsakjg 2 hours ago | parent | prev | next [-]

Since when are users in this place shy about bashing Apple?

Plenty of hate out there of apple alongside the love.

Barbing an hour ago | parent [-]

In the very same comments sometimes, those frustrating geniuses

neal_jones an hour ago | parent | next [-]

Inside of me are two wolves. One that’s like “F Apple” and another that is like “Are they going to do an M5 ultra or…?”

matheusmoreira 25 minutes ago | parent [-]

We can appreciate their hardware achievements and at the same time condemn them for their monopolistic anti-user decisions.

RealityVoid an hour ago | parent | prev [-]

Adults can hold 2 thoughts in their head at their same time.

skygazer 21 minutes ago | parent [-]

Paraphrasing F. Scott Fitzgerald? "The test of a first-rate intelligence is the ability to hold two opposed ideas in the mind at the same time, and still retain the ability to function."

Holding contradictory ideas isn't the laudable skill. Any uncritical person can believe conflicting things without being troubled by them. The genius is holding such ideas in disbelief long enough to let evidence alter or evict them.

hparadiz an hour ago | parent | prev [-]

What love? I think this is bullshit.

obilgic 3 hours ago | parent | prev | next [-]

Can this work with lume as well? Currently it has a similar limitation.

czk 3 hours ago | parent [-]

it should, lume is a thin wrapper around Apple's Virtualization.framework as i understand it

edude03 an hour ago | parent | prev [-]

IIRC you can just turn off sip and set the boot argument that controls it without a custom kernel