BASH ON UBUNTU ON WINDOWS

Overview

Bash on Windows provides developers with a familiar Bash shell and Linux environment in which you can run most Linux command-line tools, directly on Windows, UNMODIFIED, without needing an entire Linux virtual machine!
Bash/WSL allows you to:
  1. Run common command-line utilities such as grepsedawk, etc.
  2. Use the Linux-compatible filesystem & heirarchy and access fixed Windows storage mounted under /mnt/....
  3. Run Bash shell scripts and Linux command-line apps. including
    • Tools: vim, emacs, tmux.
    • Languages: Javascript/node.js, Ruby, Python, C/C++, C# & F#, Rust, Go, etc.
    • Services: sshd, MySQL, Apache, lighttpd,.
  4. Install additional Linux tools using apt.
  5. Invoke Windows applications from within Bash.
  6. Invoke Linux applications from within Windows!.
Bash on Windows runs Ubuntu user-mode binaries provided by Canonical. This means the command-line utilities are the same as those that run within a native Ubuntu environment.

Installation Guide

Prerequisites

  1. Your PC must be running a 64-bit version of Windows 10 Anniversary Update build 14393 or later
To find your PC's CPU architecture and Windows version/build number, open Settings>System>About. Look for the OS Build and System Type fields.

If your build is below 14393, try checking for updates.

Installation

In order to run Bash on Windows, you will need to manually:
  1. Turn-on Developer Mode.
  2. Enable the "Windows Subsystem for Linux (beta)" feature via the GUI or the command-line:

Turn on Developer Mode

  1. Open Settings -> Update and Security -> For developers.
  2. Select the Developer Mode radio button.

Enable the Windows Subsystem for Linux feature (GUI)

  1. From Start, search for "Turn Windows features on or off" (type 'turn').
  2. Select Windows Subsystem for Linux (beta).
  3. Click OK.

Enable the Windows Subsystem for Linux feature (command-line)

Open a PowerShell prompt as administrator and run:
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux.

After enabling Windows Subsystem for Linux

Restart your computer when prompted
It is important that you DO restart when prompted as some of the infrastructure which Bash on Windows requires can only be loaded during Windows' boot-up sequence.

Run Bash on Windows

  1. Open a command prompt.
  2. Run bash.
After you have accepted the License, the Ubuntu user-mode image will be downloaded and a "Bash on Ubuntu on Windows" shortcut will be added to your start menu.
To launch Bash on Windows, either run bash at a cmd/PowerShell command-prompt, or use the start menu shortcut.
After installation your Linux distribution will be located at: %localappdata%\lxss\ This directory is marked as a hidden system folder for a very good reason:
Avoid creating and/or modifying files in this location using Windows tools and apps! If you do, it is likely that your Linux files will be corrupted and data loss may occur. Please read this blog post for more information.

Create a UNIX user

The first time you install Bash on Windows, you will be prompted to create a UNIX username and password.


Source From MSDN.Microsoft.

Comments

Popular posts from this blog

TeraCopy Pro 3.2

Windows 7 Key Board Shortcuts