Wednesday, March 30, 2016

When Microsoft Windows met bash and Ubuntu



Subtitle:  UNIX shell and Ubuntu Binary Compatibility for Microsoft Windows

This is the week of the Microsoft Build conference.  Once again Agata and Marcus cannot attend, but one year soon, we will.  

Anyway, numerous announcements but to Marcus as a lifelong UNIX person I felt a warm glow as Microsoft announced some UNIX love.


A History
To remind newbies, Microsoft initially had, then lost the love for UNIX.

Back in the day circa 1983



- You could change the \ file delimiter in DOS to be a / so your filesystem looked like UNIX

- Microsoft released and supported their own version of UNIX System III called XENIX for several years.  The last release of XENIX was from SCO based on UNIX V.2

- Numerous companies released Unix shells or entire command suites to provide UNIX command line utilities for DOS, OS/2 and later MS Windows.  This has culminated in Cygwin which is described below.  

- For Server 2008, I recall a UNIX Subsystem Option


What UNIX love did Build 2016 Announce?

- native bash (Bourne again shell) on Windows

- native Ubuntu: Run binaries compiled for Ubuntu directly on Windows

Verge:Linux Command Line for Windows

Arstechnica: Bash and Linux for Windows




An in depth look at UNIX Linux tools for Windows







The 15 minute video is HERE ->>> In depth Link


Marcus finds in C:\Windows\System32\drivers
I did comment on February 2nd on Google Plus that I found the binaries lxcore.sys and lxss.sys on my Windows 10, Insider, development Build system.


strings -a -n 4 lxcore.sys | pg




Etcera.  Maybe these binaries and some others are to be used as the Linux layer that will ship with Windows?



What is Cygwin



For command line usage there has been the Cygwin utilities for Microsoft Windows for several years.  They are so comprehensive it is a wonder that  any serious Microsoft user does not install it.

Hell, decent OEM's like HP and Dell should pre-install Cygwin.

- www.cygwin.com

- download setup.exe

- run it, select your mirror





- choose what packages to install, the above for each section take default, or install or expand the plus and choose exactly what you want installed.



- with modern internet speeds, I now just install from Internet  (I previously used to download to local and then install)

- A typical full featured install can be at least 10 GB in size.





- Can you see the absolutely bonkers-ly large number of UNIX programs that you can install?  The above are just 2 sample categories to show you.


UNIX or Powershell
Whilst Microsoft Powershell is nice its a Windows only game.  So by learning and then using UNIX/Linux commands you can with Cygwin, and say future MS native, be multi-platform productive having learnt in depth predominantly the UNIX command line.

Of course there will always be greater support from Powershell for MS specifics like Storage Spaces etc, but these would be the exceptions where you use Powershell, reserving shell and UNIX commands for the rest.



In summary then, for me:
A GUI and command line UNIX?  Apple users have had this ever since they switched from Power to Intel and went with OSX which is built on top of /old skool/  NextStep and Mach.

Linux users, thanks to a plethora of choices, have at least 50 different distributions, with 50 different desktop experiences, it is basically a mess/ nightmare.  And I say this as a lifelong UNIX advocate.  That is the truth.

Windows, to me, has a superior GUI to any of the above, and with comprehensive UNIX command line compatibility and possibly binary Ubuntu compatibility, this could really be a great step forward.

For now, if you didn't already install Cygwin, I urge you to do so immediately.   Command line UNIX, full on is then immediately available.  You'll never look back.


Other Build 2016 Announce
15 Minute Build Announce Summary (Verge)
Channel 9, Build 2016 Full Session replay
Project Centennial