Hacker News new | ask | show | jobs
by collabs 48 days ago
I was hoping to see the bare macOS with all the applications removed as much as possible, no graphical user interface, just the bare minimum to boot, login as a user, and write hello world dot txt with a text editor. Or maybe some command line apps? Or is it no longer macOS at that point?
2 comments

You can boot regular macOS directly to a root terminal in “Single User Mode”. This was easier on Intel macs of yore but is also possible on M1+

Below content from https://eclecticlight.co/2020/11/28/startup-modes-for-m1-mac...

Launch 1 True Recovery, open Terminal, then run “bputil -a” (without the quotes) to downgrade system security and allow for more boot arguments. You might need to restart after this step.

Then, run [nvram boot-args=”-s”] (without the square brackets). Restart to launch Single User Mode.

Once in Single User Mode, run these commands (in the following order) to mount the root volume group:

1. mount -P 1

2. /usr/libexec/init_data_protection

3. mount -P 2

Future restarts will always launch Single User Mode first. To stop launching Single User Mode, run [nvram boot-args=“”] (without the square brackets).

To restore your system to full security, run “bputil -f” (without the quotes). If you choose to run that command in macOS, prefix “sudo” to the beginning.

"I'd just like to interject for a moment. What you're referring to as macOS, is in fact, macOS/Darwin, or as I've recently taken to calling it, macOS plus Darwin."

"What you're referring to as Darwin, is in fact, Darwin/XNU."

"What you're referring to as XNU, is in fact, BSD/Mach."

I seem to remember it being possible to run macOS-less Darwin several years ago, not sure if that's still possible or if Apple has modified it so much at this point that it's useless without at least some macOS components.

https://github.com/apple/darwin-xnu

Apple stopped updating this 5 years ago.

I remember getting it to boot once long ago but I didn't have anything to actually do with it.

Looks like it is still getting updates and has moved here: https://github.com/apple-oss-distributions/xnu
I now think of things in terms of token budget. I put my MacOS VM aspirations on the back burner because the effort was taking up 100 GB of space and I made poor choices when it came to laptop specs. Now I'm thinking why not rebuild XNU but I have other things I'd rather spend the tokens on. I don't want to delay other projects so I'm giving up something stupid and fun.
> several years ago

2024, maybe? needs some renewed interest perhaps:

https://www.puredarwin.org/

Needs someone to pick it up: its project leader passed away last year.