There are a few annoyances with WSL2. For me the most important are: 1. You can't connect to a port listening on WSL localhost like in WSL1, you have to figure out the WSL IP address and use that. 2. From WSL you can't connect to a Windows TCP port on localhost, you must figure out the Windows IP (cat /etc/resolv.conf) and use that. 3. The WSL remote interpreter on PyCharm is not working anymore. The suggested workar…
A solution to the IP address problem might be to write the IP address to the Linux file system when Linux boots, then read it from Windows as part of your SSH launch.
For local development in WSL my solution is to simply run a ssh server from WSL and connect to that from Windows, forwarding any ports I need. I've found the Chrome SSH app [0] to work really well (aside from needing to run Chrome), as it can forward ports and supports tmux w/ mouse control and copy paste nicely. But any decent ssh client will work.
I think it's a little sad that they are going this route (wrapping a running Linux kernel) rather than working to improve Windows disk performance and continuing to improve their WSL 1.x product. It looks like they are missing out on an opportunity to improve the NT kernel for what looks like short-term gain.
From what I understand (which is very, very little!), fundamental NT vs Linux architecture differences wrt their respective file systems prevent much more performance improvement in WSL 1.x.
They do, but NT file performance over many files scales abysmally. The two major reasons are a legacy of bad decisions: deleting files is forbidden if there are open write handles, and filter drivers are allowed to be placed between other drivers in the file I/O stack.
There's not much Windows can do about this, which causes tons of issues with e.g. git clone. Erick Smith is ludicrously smart, he just couldn't squeeze better FS perf out of WSL1 due to these issues.
I wish Microsoft would release their own linux-based OS with a compatibility layer to let me run Windows apps. I'm not overly impressed with the direction Apple is going but I really enjoy a *nix-native environment too much to go back to vanilla Windows. It would change the math a lot for me if it was full-blown linux under the hood.
I wonder whether they'll experiment with Windows compatibility in the WSL2 layer as Extend[1] phase, to possibility utalize it in a future upcoming distro creating an Extinguish[1] situation.
I wish Microsoft would release their own linux-based OS with a compatibility layer to let me run Windows apps. I'm not overly impressed with the direction Apple is going but I really enjoy a *nix-native environment too much to go back to vanilla Windows. It would change the math a lot for me if it was full-blown linux under the hood.
Why? This is a common ask, but what exactly makes a Linux kernel superior to Windows? There seems to be an assumption that Linux is the ultimate in OSes. But most of the value comes from the large ecosystem and momentum, rather than specific technical advantages.
file based system architechture makes it a winner for me.
With great power comes great responsibility, I guess. I agree it would have been nice for Linux to come with a few more sanity checks by default, like maybe a warning flag for rm -rf /* and dd commands...
I'm just more offended that the default behaviour on an extremely popular distro is failed boot = brick. You don't even get a basic command prompt to fix something, the default behavior is to lock everything down and forbid access, making it impossible to repair the machine from itself. Windows will reboot a few times and then automatically start in safe mode when this happens, you don't need to extract the drive to…
you're getting downvoted, but as a 19-year Linux fanboi, I actually agree with you. If the system has booted at least once, then it knows how to successfully boot. i.e. it knows of a string of modules, kernel, initrd image, etc that worked. As you upgrade, the OS should have a courtesy feature where it doesn't simply delete these files (unless you do the equivalent of issue a "-rf" force command). For instance, we currently have (kernel, initrd, filesystem, and modules that exist on our fs). All we would need to make it (nearly) brick-proof is to add one more thing: fallback-rd that has all the previous shit that worked last time. This would save so many users' asses at hardly any cost since storage is so cheap these days.
> The thing that annoys me most on Windows is Windows itself. After using Linuxes for almost two decades now, the notion of the OS taking tens of minutes to self update when all I wanted was to quickly reboot it is unbearable. This is definitely a problem especially considering that the shotgun approach to some Windows updates actually hurt the performance of some machines, even breaking Windows on occasion [0]. Howe…
So after a very long hiatus I have decided to try installing linux on a raspberry pi - and wow, the results were amazing. Using my decade-old knowledge of using fstab I added some drives to /etc/fstab and rebooted. Oooops. Raspbian would fail boot with a message "root account locked, couldn't open console". Fantastic - so if any of the fstab entries are missing, the entire system effectively bricks itself. The only w…
Use a gui if you don't know your way around the shell. I'm pretty sure Debian provides one.
This is really Microsoft catching up to the Mac in terms of integration with the open-source ecosystem which importantly drives the web. In the mid 2000's the Mac really took off due to being a good-enough Linux replacement on the command line, while taking care of all the hardware integration and providing a sleek desktop experience. This really helped the Mac take off among hackers. This system wasn't as open-sourc…
> I find it fairly easy to work on both Mac OS X, Linux and WSL2 -- but not pre-WSL Windows The thing that annoys me most on Windows is Windows itself. After using Linuxes for almost two decades now, the notion of the OS taking tens of minutes to self update when all I wanted was to quickly reboot it is unbearable. > I don't know how/if they're going to handle freeing memory again -- here the NT kernel really needs t…
>The thing that annoys me most on Windows is Windows itself. After using Linuxes for almost two decades now, the notion of the OS taking tens of minutes to self update when all I wanted was to quickly reboot it is unbearable.
I find the same thing with electric cars. Eight hours to charge when I've spent two decades filling in minutes is absurd.
I think it's a little sad that they are going this route (wrapping a running Linux kernel) rather than working to improve Windows disk performance and continuing to improve their WSL 1.x product. It looks like they are missing out on an opportunity to improve the NT kernel for what looks like short-term gain.
I don't think they could improve I/O speed without modifying NTFS itself (unlikely). This new approach is certainly easier to maintain and develop
You could implement ext4 on the nt kernel and have wsl1 run on it
So after a very long hiatus I have decided to try installing linux on a raspberry pi - and wow, the results were amazing. Using my decade-old knowledge of using fstab I added some drives to /etc/fstab and rebooted. Oooops. Raspbian would fail boot with a message "root account locked, couldn't open console". Fantastic - so if any of the fstab entries are missing, the entire system effectively bricks itself. The only w…
Use a gui if you don't know your way around the shell. I'm pretty sure Debian provides one.
I wanted to setup a headless Samba server - so after the reboot I didn't even have any way of knowing why the system wouldn't appear on the network anymore. I had to find the right HDMI adapter to see if the system even attempts to start as it was completely dead by all other indications.
And no, I'm sorry but I hate the argument of "you should have known better" - the system first and foremost shouldn't have defaults set up in such a way that not only the SSH server doesn't come up in case of an issue during boot, but the local console is entirely disabled for any access. That's a crazy default.
So after a very long hiatus I have decided to try installing linux on a raspberry pi - and wow, the results were amazing. Using my decade-old knowledge of using fstab I added some drives to /etc/fstab and rebooted. Oooops. Raspbian would fail boot with a message "root account locked, couldn't open console". Fantastic - so if any of the fstab entries are missing, the entire system effectively bricks itself. The only w…
With great power comes great responsibility, I guess. I agree it would have been nice for Linux to come with a few more sanity checks by default, like maybe a warning flag for rm -rf /* and dd commands...
Standard rm (coreutils) has included rootfs protections since at least 2012:
--no-preserve-root
do not treat '/' specially
--preserve-root
do not remove '/' (default)