8 ms·
Why would you need WSL/WSA when Mac is already a *NIX?
by singularity2001 4y ago
Why would you need WSL/WSA when Mac is already a *NIX?
- DaiPlusPlus 4y agoYes, macOS is a BSD - UNIX Certification and POSIX compliance is nice, but macOS does not behave the same way as Linux, which famously is not a Unix (it's even in the name), and POSIX compliance doesn't mean much today: even Windows 2000 and Windows Server 2003 were POSIX compliant with SFU. From what I gather from people with far more experience than me: if you need a "Linux-compliant" environment you're better-off with WSL2 than macOS.
- rufugee 4y agoI'd argue you're better off with macOS + something like Parallels or, if you just need ubuntu, multipass. Introducing Windows to get a Linux-compliant environment is reaching around your back to scratch your elbow.
- linsomniac 4y agoMy use case for WSL is slightly different: I work with developers who run Windows and I'd like to be able to figure out workflows that will work on their systems. A coworker today was having issues with running a Docker container that apparently had something to do with how Docker was interacting with WSL, but I couldn't reproduce on my Linux or Mac systems.
- Aaron2222 4y agoLima[0] is also great if you just need command-line Linux. [0]: https://github.com/lima-vm/lima https://github.com/lima-vm/lima
- raverbashing 4y ago> if you need a "Linux-compliant" environment I'd willing to bet some pocket money that most people claiming that don't know what they're talking about Unless you need, I dunno, DBUS? Or are specifically building stuff for Ubuntu/Red hat etc
- trissylegs 4y agoI had a lot of trouble getting any FPGA software running on Mac. But Linux it just runs/builds out of the box. Although if you have windows it also tends to run there too.
- raverbashing 4y agoAh true, some SW is built for specific Linux distros (on one side, it's hard to build an "universal binary" but on the other side, I've seen very ugly software installs)
- pjmlp 4y agoUsually are the folks that equate Linux with UNIX, and complain about other UNIXes when they don't offer Linux specific syscalls.
- rswail 4y agoMacPorts makes your Apple a Unix box in userspace and has most of the apps and frameworks and languages. WSL2 is just running a Linux in a VM. You can do that with VirtualBox and other hypervisors. You can also spin up a Kubernetes runtime that supports Apple's Hypervisor Framework.
- wil421 4y agoHow does Windows behave anywhere closer to Linux than MacOS? Why would I want my os to behave like Linux? M1/Arm compatibilities aside.
- bragr 4y agoMy mac using coworkers constantly complain that the *NIX parts of Mac are ancient and out of date and already use a linux VMs on top of Mac for better bash or whatever.
- atonse 4y agoWhich parts in particular? I’ve seen literally hundreds of developers use macOS (including myself) for over a decade either at work/ conferences/meetups and never seen them use a Linux VM apart from something like docker, etc.
- selectodude 4y agobrew install bash has always worked for me.
- philistine 4y agowhat's wrong with zsh?
- mr_toad 4y agoIt’s fine unless you need to run a bash script.
- fragmede 4y agoBut then you have to deal with a VM on top of the host macOS. IMO it's way easier to install brew, install an up to date copy of bash (which is more recent than Ubuntu has), and coreutils, and just use macOS. Having to do gls occasionally (for GNU ls) is minorly annoying, but way less work than a whole freaking VM. https://formulae.brew.sh/formula/bash https://formulae.brew.sh/formula/bash shows version 5.2.15. https://packages.ubuntu.com/kinetic/bash https://packages.ubuntu.com/kinetic/bash (well http://changelogs.ubuntu.com/changelogs/pool/main/b/bash/bash_5.2-1ubuntu2/changelog http://changelogs.ubuntu.com/changelogs/pool/main/b/bash/bas...) shows 5.2.1+debian/ubuntu patches.
- jjtheblunt 4y agoThey might be bumping into old versions of utilities up to just before GPLv3. From GPLv3 onwards, Apple has had to leave installation of newer versions of tools to users, legally, our publish their own proprietary IP, Stallman’s objective some would say.
- birdyrooster 4y agoFurthermore WSL cannot even compile anything
- deleted 4y ago[deleted]
- kiwijamo 4y agoAFAIK gcc et al works just fine in WSL.
- riolu 4y agoI used WSL2 on Windows 10 to compile the WSL2 kernel with additional flags supporting wireguard. So I'm pretty sure compiling works, maybe it was an issue with WSL1?
- birdyrooster 4y agoI concede technically yes it can compile some things but there is such a large catalog of software which fails to compile in WSL2 it’s frustrating. A great example is the many Python modules with c extensions.
- Illotus 4y agoDocker has much better IO perf with lot of small files on WSL vs Mac. Currently doing Rails development and had to revert to running local straight up on Mac vs Docker because on Docker it was extremely slow. This of course means more testing on prod like cloud envs so it is really a load of crap.
- duffyjp 4y agoI've experienced this with IO performance for huge files too. A while back I setup a caching service on a spare older Mac Mini first with Docker for macOS and when it couldn't keep up I installed Windows and it was slightly better but still crap. I threw Ubuntu on it and I was saturating the gigabit connection without breaking a sweat. I'm also a Rails dev and I do all my dev work on an M1 mac and don't even have Docker installed, though I've heard it has improved a lot recently.