
Ask HN: How do you run Linux tools on macOS - enedil
I&#x27;ve been using Linux on my MacBook for several years and now I&#x27;m considering switching back. However, there are lots of tools (mostly command line) that I used, and from what I remember, a lot of them had little quirks, installation was from times to times cumbersome, sometimes they&#x27;ll bug on something etc, etc. That&#x27;s why I thought about running Linux directly - preferably with access from terminal. I don&#x27;t suspect that I&#x27;ll need to run GUI apps. Filesystem synchronisation is a must though (I would appreciate if macos root filesystem was mounted somewhere, and conversely, linux root is mounted somewhere).<p>I would like to avoid VirtualBox and other traditional solutions, as they bring much overhead. What are some reliable setups?
======
viraptor
Homebrew where the package is available and Docker where it's not. But I'd
just stay with Linux. The only reason I'm using homebrew is because new MBP is
broken enough it can't run Linux natively.

------
actionowl
Pkgsrc is pretty good, though it often doesn't have the latest shiny util or
tool.

[https://pkgsrc.joyent.com/install-on-osx/](https://pkgsrc.joyent.com/install-
on-osx/)

~~~
atmosx
Can you share a quick pros/cons vs brew and/or macports?

~~~
actionowl
Sorry, I've not used brew or macports. I also use NetBSD and SmartOS, and they
too use pkgsrc so my familiarity with it might be some of the reason I use it.

------
mattbillenstein
brew install coreutils findutils gnu-sed gnu-awk curl ...

And add coreutils to your path:

export PATH="/usr/local/opt/coreutils/libexec/gnubin:$PATH"

