4 ms·
It needs a VHD, which requires setting aside a partition of your disk, meaning you can't dynamically share space with your Windows files. That's a huge downside
by mehrdadn 7y ago
It needs a VHD, which requires setting aside a partition of your disk, meaning you can't dynamically share space with your Windows files. That's a huge downside for me. (By "partition" here I'm just referring to the English sense, not the MBR/GPT per se.)
You also can't nor search/modify your Linux files directly from Windows like I mentioned. The 9P server with WSL1 has been so slow as to be unusable for some directories when I try to use it. Does it feel native SSD-speed on WSL2?
As for RAM, does it really share RAM with Windows? That's great news if it does, but I don't think I've seen any VMs do this, though I've never tried it with Hyper-V... if it does,
I'm guessing that's what lets it use memory ballooning?
- eropple 7y agoIt's a resizable VHD that handles its business in the background, so I don't understand the complaint. And you can access your Linux files in Windows just fine when using WSL2. Just go to `\\wsl$`. WSL2 is the first thing to legit make me reconsider my daily-driver Fedora setup in...well, since I started using it in ~2016. I just do not think about it, it's great.
- mehrdadn 7y agoIt shrinks the VHD automatically?? And yes the \\wsl$ is the 9P server I just tried to explain is incredibly slow compared to normal files on WSL1. I haven't tried WSL2 yet but I don't expect going through a VM would be faster.
- eropple 7y agoI've never looked as to whether it shrinks it, but I assume not (that would be hard). OTOH, storage is cheap, so I've never really worried. I never used WSL1 in anger, but accessing WSL2 over the \\wsl$ is not particularly slow. It's not as fast as native, but I don't notice it. I do almost all of my access of files on the Linux image via a terminal and VSCode-over-WSL-Remote, though.
- mehrdadn 7y agoWell "storage is cheap" for you but why assume my money and everyone else's is cheap? I'm low on space and I need to shell out hundreds of dollars to get a larger version of what I have just to use WSL2. Or I could just keep using WSL1 and save my money, especially in this economy. Why in the world would I get a new SSD just for WSL2? This isn't about using it "in anger". I'm not pushing it to some kind of corner case, you just need to use it for real instead of trying hello-world examples. You notice this immediately as you're dealing with nontrivial folder contents. To give you an idea, this is the speed of raw grep from inside WSL1 Ubuntu: $ time sudo grep -ri asfadsfadf /etc real 0m0.075s user 0m0.016s sys 0m0.063s This is the speed from \\wsl$ (MSYS2): real 0m9.227s user 0m0.078s sys 0m0.561s And this is the speed on the raw files from Windows (MSYS2): real 0m0.092s user 0m0.000s sys 0m0.046s \\wsl$ is literally some 60x-70x slower than direct access, and it's not because I'm "using it in anger". If you don't believe me, try it yourself with any program you prefer and see if you get similar speed before you tell me I'm wrong. This is par for the course on \\wsl$. Explorer lags, too, if you try to browse a folder with a bunch of subfolders that actually have some contents. It's plain as daylight to me. Not noticing to me is like not noticing that your car suddenly goes 1mph instead of 65mph.
- tilolebo 7y agoThat has been my experience as well. WSL2 is much much faster.
- rfoo 7y ago> resizable VHD Just like what you normally use with a Hyper-V VM. A resizable VHD which grows but not shrinks, and with a size limit. Heck they even have a document on what to do when you exceed the default 256GB limit: https://docs.microsoft.com/en-us/windows/wsl/wsl2-ux-changes#understanding-wsl-2-uses-a-vhd-and-what-to-do-if-you-reach-its-max-size https://docs.microsoft.com/en-us/windows/wsl/wsl2-ux-changes...
- Dylan16807 7y agoSupposedly it can release memory, as of October. It wasn't working in January when I last tried it, but I guess it's worth putting it back on auto to see what happens.