I haven't dug deep into it yet. But, I'll say that I've been having fun compiling (command line) Linux apps with Clang and visually debugging them with GDB all through the UI of VStudio Community Ed and without a VM. /shill mode
Linux is not a target for the code I'm working on. But, I like to keep my code as cross-platform as possible. Between this setup and prototyping code on several compilers via goldbolt.org, staying standard-compliant and compiler-agnostic is much easier than ever before.
Network filesystems! That's the last big feature I've been needing for regular use of WSL for light tasks. There's still enough weird behavior I wouldn't look at WSL as a complete Linux replacement, but it sure is a lot nicer than Cygwin/msys2.
They don't say anything about FUSE, I wonder if this work is at all related?
I am pretty sure this update does not add FUSE support.
FUSE would add the ability to use SSHFS, which is the network file system support I'm interested in.
There is a Windows-native SSHFS client[1]. I have it installed on a Win10 VM so can confirm it "works" albeit I haven't needed to use it for anything so cannot confirm how well it works.
I helped resurrect this to support Windows 10 a year or so ago. It works, but because of its reliance on Dokany (a FUSE-like usermode file system library), there are a lot of ways it still doesn't work perfectly.
It was a lifesaver for me when I was doing development on embedded Linux devices (Pi/Edison et al). But if you're not tied to remote hardware, WSL is an infinitely better, faster, much more reliable dev process.
The biggest issue I ran into with win-sshfs was its tendency to bodge git repo status if you maintained the repo on the mapped folder.
What do you mean by "bodge git repo status"? One thing I noticed is that, git gets confused if you clone under Linux and then try to access it via win-sshfs from Windows. The other way it works fine, i.e. clone from Windows, then other actions work fine on both sides.
Any idea if filesystems mounted with that SSHFS client are now visible under WSL? They weren't in the original WSL release and I'm guessing aren't under the recent Creators Update release. But maybe they are with this new DrvFs?
WSL is really interesting. I switched to the Mac in 2006 but I’ve never really used the fact it’s built on Unix much because it’s so different and frankly outdated comparede to the Linux systems I work on. When I want to do ‘Unixy’ stuff at home I run a Linux VM in VirtualBox. But WSL seems to offer the best of both worlds – a solid mature desktop environment with plenty of well supported professional level apps and an approaching first class Linux environment baked right in. I’m still very happy on the Mac and would miss a lot of Mac specific features and applications, but this is the first thing to happen in Windows Land that’s made me even think of the possibility of wanting to run Windows at home for over 10 years.
Edit: What would be the nearest thing to WSL on a Mac? VirtualBox is a bit heavy-weight. Maybe something based on Hyperkit and Docker?
Likewise - except for me it's been 15 years. Switched over in 2001, and didn't look back. Running WSL creators edition is really a delight. It's not quite there yet - still has a year or two to bake - but the progress is great. They just added serial support yesterday (which is important for a bunch of the linux binaries I run). For the very first time I'm honestly considering sitting down to a Windows System to do work - I never thought I would have said that - I've got * nix in my finger DNA, so powershell, despite being incredibly powerful, just never managed to get into my workflow.
But now - It's best of both worlds - solid User Environment + Solid Unix CLI. Even better, it's a linux CLI, which means I get all the apt-get goodness that I've been missing on OS X (which admittedly has a pretty good brew install infrastructure).
For me at least the big problem is malware. Running Arch Linux means I do not need to worry about malware. Ransomware. Crap like that. Yes, I am a reasonably experienced computer user and it's quite unlikely I would click anything "wrong" but not having to worry about a single bad click causing hours of recovery is a big plus.
Edit: while I understand downvotes I would be much happier if you'd educate me where I am wrong.
If you avoid the darknet/warez and use Windows defender and Windows security essentials (MS antivirus), you will largely forget this was ever an issue with Windows.
Even my parents, love them, haven't had a single piece of malware or a virus since I forced Windows 10 upon them (from Windows 7). They were not happy at first, but the number of calls I get for "why is my computer so slow" and "what is this thing that keeps popping up" have dropped to 0.
Running Arch Linux means I do not need to worry about malware. Ransomware. Crap like that.
I didn't downvote you and understand your concern. However, keep in mind that X11 has no GUI isolation. So, an attacker could snoop all your keyboard and mouse events, make screengrabs, etc. through a compromised web browser.
Wayland provides GUI isolation, but is not widely deployed yet. Most X11 users are only safe because the X11 desktop is not a large target group, but it is probably less secure than Windows, which does GUI isolation between processes of different privilege levels, sandboxing for Store apps, etc.
That's true, but it only matters once the attacker manages to run code - which is significantly harder to achieve on Linux, due to diversity (opposite of win monoculture) and mostly sane defaults (no local directory in executable or dll search directory; file name not enough for execute permission).
Buffer overflows and targeted attacks are comparable in ease, but if you are not targeted, you are way safer on Linux.
So there's a chance someone could snoop on me using X11, but there's a 100% chance of it on Windows because of all the data they're collecting in the background (including being able to get a copy of a file that triggered a crash).
Beats the heck out of me - you make a good point. Windows Systems are certainly more popular targets for Malware than ArchLinux/OpenBSD. I absolutely agree with you that if just want to not deal with that (and still actually use the Internet) - getting off the major platforms is a pretty straightforward play.
But - if you want to use all the Tier 1 Commercial software (or, in the cases of things like garageband, free software ) - kind of hard not to have a Windows or Mac.
All experienced Windows user have a curated list of software. If you download shady apps, sure, good chance of getting infected. But Chrome, Firefox, TotalCommander, 7-zip, Sublime, etc., etc. are all free, mature and malware free.
It may not be as conceptually easy as Arch Linux but on the other hand you get access to Windows-only stuff which has its benefits.
And almost any Linux user should be able to create that curated list within 6 months, IMO. If they aren't, then I doubt even their Linux chops...
Installing apps on Windows is 100% as easy to do now as it is with Homebrew and Linux package managers with Chocolatey. I don't download software anymore on my Surface; I choco install EVERYTHING.
I was even surprised to discover today that I could install IntelliJ via choco install! It is amazing.
If there was Hckrnews gold, it'd be yours. This alleviates a lot of problems I constantly had with Windows, namely downloading crap from who-knows-where then contains who-knows-what. This actually might be the deciding factor.
In my experience, no. They only just recently added support for executing apps between environments.
Executing Windows apps from the bash shell can be surprising:
$ notepad
The program 'notepad' is currently not installed. You can install it by typing:
sudo apt install wine1.6
$ notepad.exe
(Note Pad is launched)
$ /mnt/c/Windows/System32/notepad.exe
(Note Pad is launched)
In the latest builds symlinks no longer require administrator permissions.
Don't know what you're referring to in regards to permissions mappings, but know that the Windows' permissions always trump whatever your see from chmod/ls -al
Cygwin (64bit) didn't work for me in the latest creators update (actually I think it broke even before that). Now I am trying things using WSL itself, so far it has been a productive move.
File permissions and security descriptors proved to be quite a hassle when removing Cygwin requiring multiple takeown and cacls hacks to remove some of the files.
OTOH when I wanted to have pretty pictures on my lock screen but without the Microsoft ads, I needed to rely on Cygwin to blow away the folder that caches the pictures deep in ProgramData/.../SystemData/*/ReadOnly - the lock screen image setting API has a lot of bugs. Without Cygwin, I was fiddling with cacls and takeown in an elevated prompt trying to blow away the folder. An elevated Cygwin prompt and it was just rm -rf.
Sometimes elevated command prompt is not powerful enough and you need command prompt running from "SYSTEM" user account (Windows NT equivalent of Unix "root"). You can get that one with psexec tool from Microsoft SysInternals:
psexec.exe -i -s -d %WINDIR%\System32\cmd.exe
There's no real equivalent of root on Windows. Accounts can have capabilities (pronounced 'privilege' [1]), and securable objects have ACLs and ownerships. Owners can replace ACLs, and a capability can give the ability to unilaterally change ownership[2]. And some of the more recent changes (to increase security for naive users) have been to disempower users and relinquish capabilities.
Accounts like SYSTEM may be functionally similar to root in so far as they may have the grant option on capabilities and thus have the keys to unlock powers, but good privilege separation design suggests that capabilities shouldn't be idly taken up.
Functionally, an elevated prompt had enough power to blow away the directory I wanted to delete - that is, the account had the capability to take ownership, replace ACLs, and then delete the objects - but following all the steps is fiddly. Cygwin abstracts all that away to the simplified POSIX system.
Something like SYSTEM may have been enough for different reasons; the existing ACLs may have permitted deletion to SYSTEM. But that doesn't mean SYSTEM had more intrinsic abilities (though I believe it does have more capabilities [2]).
I wonder if they have plans to add other emulation features, most importantly the ability to passthrough USB devices (or even graphic cards?).
I don't need or want the Linux graphical interface of my VM, it's pretty much redundant, but I do need to make devices available to the Linux software. Otherwise it's a bit like emulating a microcontroller - sure, Turing says the thing can compute everything, but in a very practical sense it can do absolutely nothing without it's outside inputs and periphery. I need the damn side-effects!
Works great for bioinformatics too. I've exited the Apple world (high prices etc.), and don't miss much now.
No longer have to modify Powershell to make it more Unix-like. Jupyter notebook works fine, so I'm happy. No more bother with dual booting either; Ubuntu is gone as well.
The irony is real. The only selling point for macOS right now is the unparalleled vertical integration, iCloud+ iPhone + Handoff etc. And also beautiful hardware that usually just works.
Yeah, as an iphone user it's the handoff stuff that keeps pulling me back to macOS. It's really handy, especially with cross-device cut and paste recently. However, I've also been using WSL and it has really impressed me. I need to check on the current state of similar windows<->android stuff before my next round of purchases.
MSFT are not the only ones in the Linux ABI emulation game. Illumos and FreeBSD are doing it too.
The Linux ABI is still a moving target, but it's moving much more slowly than a decade ago, so you can now expect every OS to start emulating it (warts and all).
I understand. Nonetheless they did to the work to enable straightforward client networking (which works because Windows' own networking layer is basically Berkeley sockets under the hood).
Writing an emulation of the Linux USB sysfs and device node API on top of Windows' very different USB driver layer is a rather bigger task. I'm sure they'll get to it eventually, but it's not something you can demand as an "obvious" feature.
Tangential, but there was a recent HN article (I think) (that for the life of me I cannot find a link to) that referenced a Microsoft DSL for describing finite state machines that was principally developed to implement MS's USB driver. Closest link I could find (which is not the correct one) is: https://www.microsoft.com/en-us/research/project/model-based...
I wish there was a way to get lxss updates without being a Windows Insider.
I turned on Insider on my brand new laptop last summer and it immediately overwrote some vendor-supplied drivers by newer-but-broken ones. Result: no sound. I didn't manage to fix it except through a full reinstall. Now that's exactly the sort of problem you need to prepared for when doing the Insider thing, but it sortof ruins the point. I want to beta test lxss, not Paint 3D or some fancy new device driver release schedule.
I'm pretty certain I had WSL running on my system without being a member of Windows Insider. You just need to turn that on if you want to be on the Fast Track...
I thought this WSL update came with creators edition? Unless you mean the fast track WSL Updates, but not the other windows updates - which yes, I agree, would be nice.
It's a Windows subsystem[0] for [running] Linux [applications].
The terminology is "Windows subsystem for [target environment]" so "Windows subsystem for OS/2" lets you run OS/2 application on NT, "Windows subsystem for Win32" lets you run Win32 applications on NT, and "Windows subsystem for Linux" lets you run Linux applications on NT.
[0] "The interface between user mode applications and operating system kernel functions […] There are four main environment subsystems: the Win32 subsystem, an OS/2 subsystem, the Windows Subsystem for Linux and a POSIX subsystem."
The Architecture of Windows NT page on Wikipedia has a good diagram to help visualize NT subsystems. The first few versions of NT, iirc, shipped with the OS/2 subsystem but this was removed with Windows XP.
It's confusing, but accurate. It's a subsystem of Windows ("Subsystem" is a well-defined term in Windows land, the win32 API is o its own subsystem as well).
I wish they had promoted the name lxss more, though. It's short, very googlable, and it's the internal name.
Android is Apache 2.0 with the Linux / GNU parts retaining their respective GPL licence. Microsoft are distributing the OS for free, which is allowed within the terms of Android's licencing and something that is done by many other organisations including Google themselves.
I work for the company, mostly use a Mac, sometimes use X11, and started laughing when I read X11 server on WSL/Linux on Windows. Things have come a long way. I don't know if there is X11 support, but when I have some time later this week, I am going to look based off this question and see. I'm having visions of Hummingbird Exceed from back in the day at the moment.
I'm not being flip, I'm actually curious as well and will try figuring out when I have a spare few moments.
The free version of Xming does not implement several things properly. Not sure which but some applications haven't run properly. There is a charityware version but I can't find my license for it.
MobaXterm is another free version, It's a term emulator with an X11 server, but you can just turn it on and ignore the term. It runs all the applications Ive found that the free Xming cant.
Is it at the point where one can, for example, use PyCharm to develop Python/Django sites residing in the Windowns file system (say, z:/sites/project_099) while hosting from WSL?
Or would it be treated more like a VM that you simply deploy to?
We currently run one or more Ubuntu server VM's per machine as needed for local testing. If needs go beyond that, we have physical (virtualized) servers on our network (for example, web and database servers).
I can see WSL possibly being good for local development if it can somehow integrate seamlessly with the Windows file system and various tools (PyCharm) can be setup to run on Windows yet talk to WSL. I guess this might be equivalent to running a remote interpreter.
Need to think about this a bit. Running a server or two on VMs is pretty clean and painless. On machines with 64 GB of memory you don't even know they are running (from a performance/resource perspective).
You can cd to /mnt/z/sites/project_099 and work there directly in WSL. Open the same files in a Windows-based text editor. Even use Visual Studio to drive gdb debugging of the Linux process in WSL.
I've not done that last bit, but I definitely have moved all my ruby/Jekyll work into WSL and use VSCode to edit.
I was going to make another comment, but just found out while searching that WSL is //supposed// to be based on Ubuntu (20)16.04 now (instead of 14.04) I guess the next time I work with those systems I'll have to run down some upgrade / re-install directions.
I wonder if that will fix the issue where I was unable to mv folders around the c:\ drive within the /mnt/c FS. (It more or less locked up to the point that I had to restart to clear the issue.)
FWIW, I haven't had any issues moving files before or after upgrading from 14.04 -> 16.04. I use Git in WSL, but interact with the files in both Windows and WSL without any special considerations.
With the updated WSL version out I probably won't ever run across the issue again. I can't remember the exact circumstances, I may have had the folder open in a window or something (thinking of it, Windows doesn't let you rename files out from under processes, which may have been the reason).
However I do recall that trying to ctrl+c kill it didn't work. I don't recall what else I had/hadn't tried; I was rather busy at the time and couldn't stop to make a proper bug report.
All that mattered to me was that it completely stalled for no transparent reason and my best option was to just not even try to do real file management from the WSL environment.
Your Windows drives appear under /mnt/c, /mnt/d, etc. in WSL. So your Windows home directory is /mnt/c/Users/ffoobar.
You can easily read/write Windows files from Linux, but I don't think you can do the opposite. I've used git within WSL to drive a repo on my Windows drive.
WSL gives you full-blown Ubuntu 16.04 where you manage packages with apt-get. You have to look close to the bare metal to see differences. Until the creator's update, for example, ifconfig didn't work.
Earlier today, I compiled and ran some OpenMP-based code in WSL and it happily detected all the cores on my dev machine and kept them busy with worker threads. Pretty cool!
It does but you have to do that from the Windows file system not the Linux one. So from Linux you are accessing /mnt/c/Users/you/somedocument and from Windows it's C:\Users\you\somedocument.
No, it's always been that way from the initial release. It's literally the only file system interopt that exists.
You're not supposed to access the Linux filesystem from Windows -- it's in a system hidden area of your profile but some people still tried to mess with it with unfortunate consequences.
I know that apt-get works since earlier instead of the terrible Cygwin distribution model, but yes, IIRC there are NTFS streams being used for the Linux file system metadata IIRC and if these get overwritten or somehow modified things go bad. And NTFS streams being a somewhat uncommon NTFS feature, some applications don't handle them well?
On the other hand, wasn't a new Windows 10 Creators Update feature that you could now indeed edit the files from Windows, and not just from the Linux subsystem? And that the Linux tools such as web servers are now even notified when the files change so they can reload them automatically? I'm not sure how they solve the metadata borking issue though, in that case.
It's already on the stable Windows 10 build a, and there was also significant improvements in the creators update. You have to enable it via "Windows Features" and reboot before first use.
Java still doesn't work properly though =(. "mvn clean package" on one of corporate projects takes about 5 to 8 minutes in native java on Windows or Mac and it takes more than one hour in WSL. I had so much hope for WSL that I would finally have only ONE device (surface), but no, we're not there yet.
Five to eight minutes? That sounds horrible.
Have you tried concurrent compilation with "mvn -T 1C"? Gets our build time down from 3 minutes to 1 minute, but we have lots of smaller projects.
Well, that's a clean build of more 500 megs of source code and includes NPM building frontend and lots of other fancy plugins for generating docs and stuff.
We have a build system which is built around maven with *nix only in mind. It does a lot of handy stuff and 99.999% people in company are on macs, I just wanted to have one device instead of two so I was trying to use surface. I keep trying it like once or twice a year and then back to my Mac + iPad + Apple Pen mainly because of that. I also tried to run Linux in hyper-v and use shared directories but io perforce is quite poor in this case too.
I would love this because I still want a 'real' shell when dealing with Java - things like emacs, grep, find, etc.
Cygwin and using shared VM directories has too many glitches with things like npm, links, file system endings, etc. As Docker becomes more important, this gets even worse.
Really, developing on a Mac is just so much better than both Windows and Linux, even for Java.
Linux is not a target for the code I'm working on. But, I like to keep my code as cross-platform as possible. Between this setup and prototyping code on several compilers via goldbolt.org, staying standard-compliant and compiler-agnostic is much easier than ever before.