7 ms·
WSL 1.3.10 Brings Experimental Memory Reclaim, Updated DXCore and Linux Kernel
- baq 3y agoCan’t for the life of me understand why macOS doesn’t have this. WSL is so much nicer to develop in than macOS docker.
- jarym 3y agoFor a long time macos was close enough to *nix that it was far better than Windows for developers that need a Linux-like terminal. WSL might be seen as Microsoft's attempt to catchup and in many respects they leap frogged macos for this set of users. I don't see Apple putting in the same level of effort to create the WSL experience on mac but who knows. Hyperkit could be quite a nice base to build on. The only issue I've run into is that there are more gotchas with podman & docker when running the ARM macs but that's only because so many images are still x86-only. Edit: Darwin has BSD roots and FreeBSD offers Linux binary compatibility.. I wonder if it could be brought to macos (would be a huge undertaking though since there are SO many differences between Linux and modern macs).
- dgl 3y ago> I wonder if it could be brought to macos (would be a huge undertaking though since there are SO many differences between Linux and modern macs). That sounds like trying to recreate what Microsoft did with WSL1*, which is an emulation layer for Linux on Windows. They realised that was a mistake (things like cgroups and container support are complex and slightly different implementations led to subtle bugs). Now WSL2 is a whole Linux kernel running in virtualisation. The "clever" bits are now the glue (file sharing, even if that has performance limitations) and some things like WSLg, which sadly they still keep as their own fork and haven't upstreamed yet. *: As touched on in other threads, despite the version number of 1.3.10, most of the features they are talking about, such as actually using a real Linux kernel are for "WSL2".
- yjftsjthsd-h 3y ago> which is an emulation layer for Linux on Windows. They realised that was a mistake (things like cgroups and container support are complex and slightly different implementations led to subtle bugs). In the meantime, FreeBSD, NetBSD, and illumos have all had Linux ABI compat since long before WSL1 and are doing fine - not perfect compatibility, but quite good. If I were guessing, I would guess that papering over the difference between members of the unix family is easier than between unix OSs and NT.
- FooBarWidget 3y agoMicrosoft's lesson suggests that actual user needs have evolved passed the point where FreeBSD-style emulation compatibility is good enough. Users are no longer content with "good enough" Linux compatibility, they want perfect Linux compatibility.
- deleted 3y ago[deleted]
- baq 3y agoLast time I tried WSL1 it couldn’t run Postgres, which was immediate disqualification for my backend work, if you could live with the slow git. WSL2 runs Postgres, docker and basically anything, and git is as fast as native if you stick to WSL2 file system. The quote is misrepresenting issues with wsl1.
- yjftsjthsd-h 3y agoTwo thoughts: * As I sort of mentioned, I suspect that the others may actually do a better job of compatibility than WSL1 because they're on unix-likes already so there's less fundamental differences to try and make compatible. For example, fork() is already cheap, and unix-likes already have filesystem performance like Linux. * A binary compatibility layer is less important to begin with since you're already on a unix-like. For example, sibling comment says postgres didn't work; FreeBSD already has postgres as a fully supported native package, so you're unlikely to care how it runs under the Linux compat layer.
- Vecr 3y agoTechnically MacOS is UNIX but at this point what people actually want is Linux-compat and possibly FreeBSD/OpenBSD stuff, as you said. MacOS is *nix.
- chungy 3y agoDarwin's FreeBSD roots are not very large (basically some of the userland terminal programs). It was never based on the FreeBSD kernel and that's where FreeBSD's Linux compatibility really resides.
- comex 3y agoThat’s not true: xnu has significant parts originally copied from the FreeBSD kernel, alongside the Mach parts and the IOKit parts. However, considering not just the changes made in the process but also the ~20 years of independent evolution since then, I wouldn’t count on anything from the modern FreeBSD kernel being easy to port. Probably easier to start from scratch.
- epolanski 3y agoOne key difference between Apple and Microsoft on this regard is that Microsoft needed such a tool internally: after all given the importance of Azure in Microsoft's ecosystem Microsoft developers need machines able to handle Linux workloads. I know for a fact that Microsoft sees it as a defeat internally that their own developers would rather have a macbook over the company-issued Surfaces or similar windows laptops. So easing the pain of working on *nix machines is a top priority for enterprise Microsoft users. That's not really a huge issue for Apple, they are neither in the business of selling linux virtual machines nor their ecosystem offers such a huge gap to native linux after all.
- pjmlp 3y agoBecause it is a certified UNIX already?
- metaltyphoon 3y agoExcept that’s a terrible solution ,when working w docker, compared to WSL.
- pjmlp 3y agoHere is a secret, you don't need Docker to develop on UNIX.
- metaltyphoon 3y agoAnother secret, I rather not litter my environment with 100 different tools.
- pjmlp 3y agoAnother one that has lost the path, https://en.m.wikipedia.org/wiki/Unix_philosophy https://en.m.wikipedia.org/wiki/Unix_philosophy
- fodkodrasz 3y agoSo is this WSL 1.3.10 or WSL2 1.3.10? The Microsoft custom to confusingly name stuff goes on, in accordance the spirit of the Yoda-speak Windows subsystem for Linux... ps.: the new features are nice, I like WSL2 and use it quite a bit sometimes.
- jmgao 3y agoIt could be worse, it could be Java 2 Standard Edition 5.0 1.5.0 release 22!
- Sakos 3y agoI still don't understand Java versioning. Apparently the latest JRE is still 8u371? Is that Java 8? How does that relate to the SDK I use which is 17 or 20?
- erik_seaberg 3y agoI don't know if upstream ships it but I think JRE still exists as a build target. Debian stable at least has packages like openjdk-17-jre, and unstable has newer.
- blackoil 3y agoOracle no longer releases JRE post Java 8. Users are not supposed to install it as Applets and WebStart are no longer supported. Post 8 only JDK is released which has bundled runtime environment.
- TeMPOraL 3y agoBonus questions: why do I seemingly need to have both Java 8 and Java 11 installed on my work machine? But specifically some $RandomCompanyName Java, because Oracle Java and OpenJDK seem to be disallowed by corporate policies, and there are scanning tools running like hunter-killer drones, ready to snuff out any traces of openjdk and nuke it from orbit? And all I need it for is to run some PKI software that looks like it was written in the 90s? I've lost track of what's going on with Java ecosystem, at least on the enterprise side.
- leovander 3y agoI'm waiting for https://github.com/microsoft/WSL/issues/10006 https://github.com/microsoft/WSL/issues/10006 to be resolved without using the work around mentioned in that issue and all the duplicate issues closed before it, before I can reliably recommend the less technical folks on my team to use wsl.
- nailer 3y agoHrm, my clock skew issues (mainly after recovering from sleep) all went away in the last six months and I am on stable.
- dboreham 3y agoTry an ARM machine.
- leovander 3y agoI'd have to double check if there is a difference in behavior between manually setting the computer to sleep vs the computer sleeping on its own after inactivity. I think the former may reduce the skewing, but if I walk away from the computer for a tad too long and wake the computer back up, it'll take me a bit to realize why my 2fa to my local server running in wsl keeps expiring.
- dboreham 3y agoI'm there too.
- 8n4vidtmkvmk 3y agoOh.. cool. Is that what broke my Docker project last week? Was complaining about clock skew.
- TeMPOraL 3y agoOkay, but now I'm left with the usual question: is that a WSL 1 issue, or WSL 2 issue?
- nailer 3y agoWSL daily is great, and generally better for the software development than MacOS, but every six months you have to stop WSL and run a scary command line tool to get your hard drive space back. https://github.com/microsoft/WSL/issues/4699?ref=blog.dan.drown.org https://github.com/microsoft/WSL/issues/4699?ref=blog.dan.dr...
- dboreham 3y agoUsed it on many many machines since first release and never had to do that.
- ghusbands 3y agoReaching >100GB of host disk usage for <10GB of guest disk usage is clearly very significant. I'm glad you've got enough spare hard disk space or little enough file churn that you've not noticed it.
- kramerger 3y agoNo need to run a scary command, hyperv has a UI for this. Personally, i never had to do this
- nailer 3y agoMy Microsoft Surface device does not include Windows 11 Pro so it costs 120 GBP, about 155 USD, for me upgrade to Pro to get that tool. It’s great that you personally don’t have to do it. Maybe you don’t often delete files from the linux drive. Maybe your hard drive is large. I know other people that have to do it once a month. That is how storage works.
- aulin 3y agohow is that better than macos? what kind of sw dev? doesn't macos + iterm2 + brew have all the linux tools one could desire?
- nailer 3y ago
- kristianp 3y agoRelease notes at: https://github.com/microsoft/WSL/releases/tag/1.3.10 https://github.com/microsoft/WSL/releases/tag/1.3.10
- crazysim 3y agoVery cool! With the memory reclaim, that's going to be neat for long uptime Window systems. That said, I wonder if they fixed a memory leak in wsl.exe I reported that Docker Desktop seems very keen on making more and more of. Hundreds of thousands of handles leaked after a week uptime: https://github.com/microsoft/WSL/issues/9851 https://github.com/microsoft/WSL/issues/9851 DD is a POS, so ah, whatever.
- nickjj 3y agoFor those who don't want to upgrade yet or enable experimental features, you can drop your cache manually to reclaim memory. I've been doing it for years now, it works: https://github.com/microsoft/WSL/issues/4166#issuecomment-628493643 https://github.com/microsoft/WSL/issues/4166#issuecomment-62...
- Jemm 3y agoI am confused. wsl --version gives "WSL version: 1.3.11.0"