Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Make your voice heard. Take the 2019 Developer Survey now

Questions tagged [windows-subsystem-for-linux]

Windows Subsystem for Linux (WSL) is a compatibility layer that allows Linux ELF64 binaries to run natively on Windows 10

4
votes
2answers
5k views

Linux Subsystem for Windows cannot access the Internet

For some reason my Bash on Ubuntu on Windows is unable to access the Internet. I.e. when I do sudo apt-get update I get a bunch of failed fetches. Exactly as the issue describe under this link. I ...
18
votes
3answers
25k views

How to run Ubuntu service on Windows (at startup)?

I want to launch an SSH server on Linux subsystem (Bash on Ubuntu on Windows) at windows startup. The problem is that all Linux processes are terminated when Bash window is closed. Is there a way to ...
2
votes
2answers
2k views

Force lowercase hostname in Windows Subsystem for Linux

I've set my computer name to lowercase in the system properties. In cmd.exe it shows as lowercase. However, in Windows 10 Bash it shows as uppercase, even though the /etc/hostname file has been ...
90
votes
5answers
136k views

How can I SSH into “Bash on Ubuntu on Windows 10”?

I have Windows 10 Anniversary Edition with "Bash on Ubuntu on Windows" installed and working. I'd like to be able to SSH into this Ubuntu instance, but although I have openssh-server installed and ...
0
votes
1answer
549 views

warning when running simple shell script in bash for ubuntu on windows

So I've activated and installed Bash for ubuntu for windows, great! Now I'm trying to write a simple shell script, but I get stuck. This simple example script from here below runs fine on my linux ...
43
votes
7answers
38k views

How to access linux/Ubuntu files from Windows 10 WSL?

This question answers how to access Windows files from Ubuntu Bash, but how can I do the opposite? Specifically, I need to access my SSH key from Windows which is located at /home/mark/.ssh/id_rsa ...
9
votes
3answers
5k views

How to change default shell for Linux susbsystem for Windows

I've installed Linux subsystem for Windows 10. It works fine, but I want to change the default shell environment for the subsystem. I did sudo apt-get install fish and then chsh -s /usr/bin/fish. ...
0
votes
1answer
1k views

New bash on windows 10 cannot use gulp

I installed it yesterday, and I cannot find a way to bypass all the errors I get: [nodemon] Internal watch failed: watch /home/user/myFolder/whatever EPERM listen EACCES 0.0.0.0:80 These works on a ...
4
votes
4answers
2k views

Associate SH scripts to Windows bash

How can I associate all .sh files to new BASH included in Windows 10 Anniversary update? I have tried associating .sh file using default system prompt to C:\Windows\System32\bash.exe but it just ...
9
votes
2answers
13k views

Is it possible to run networking commands like nmap in WSL?

I recently got the Windows 10 anniversary update and installed bash. I tried installing nmap, but it wouldn't run. My question: Is there any way for commands like nmap to correctly run in WSL? ...
0
votes
0answers
99 views

Bash on Windows doesn't seem to run just an underscore blinking

I followed instruction enabling bash on ubunutu on Windows 10 and it run ok first time. After pressing Windows button typing bash and runnning it I only get a console window with an _blinking: Anyone ...
1
vote
2answers
339 views

WMIC in Windows Bash

When I try to use WMIC in Windows Bash, it says command not found. Though, in git-bash and Cygwin I am able to use WMIC, so how can I achieve this in Windows Bash?
15
votes
4answers
14k views

Where is the Windows bash directory in Windows?

I've installed the Windows 10 Anniversary Update on my computer. I would like to know where the /root directory in Bash prompt is within Windows? I would like to be able to write files in Bash that ...
2
votes
0answers
1k views

Windows 10 Linux Subsystem. initctl: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused

I install MongoDB (in Linux Subsystem) with sudo apt-get install mongodb and when I try to start it with sudo service mongodb start I have the following error User@DESKTOP-TPQIRNP:/mnt/c/Users/User$...
0
votes
0answers
73 views

Windows Subsytem on Linux, “sudo: can't resolve hostname” [duplicate]

I have just installed WSL and i am running into a number of issues. The first being that i can't change the locale to en_US with out using SUDO. When ever i use SUDO i get "sudo: can't resolve ...
22
votes
4answers
21k views

Is it possible to have tabs in the new windows 10 bash terminal?

Is it possible to have tabs in the new windows 10 bash terminal? It would be really useful.
5
votes
3answers
8k views

Windows 10 Linux Subsystem How to Change User Name and PC Name for Bash Console

When I first installed and ran Windows Linux Subsystem, console askded me to enter a new user name for bash. I input User. Now when I start bash in my console my username and PC name appeared at the ...
3
votes
2answers
2k views

Adding Bash on Ubuntu on Windows 10 to Explorer Context Menu (Issues)

I have successfully added the Bash on Ubuntu prompt to the context menu by adding the following registry keys [HKEY_CLASSES_ROOT\Directory\shell\bash] @="Bash Here" [HKEY_CLASSES_ROOT\Directory\shell\...
11
votes
3answers
11k views

Windows 10 bash and mintty

I just installed the new Linux subsystem in Windows 10. It's really nice to have access to the Ubuntu repositories, but I absolutely HATE the default cmd program. Cygwin's MinTTY is really nice and ...
3
votes
3answers
2k views

How to access the windows linux subsystems filesystem from windows?

So, from the linux subsystem bash I can access the windows filesystem in /mnt/c but I'd like to access the linux filesystem from something like explorer, is this possible?
33
votes
3answers
26k views

Accessing removable media in Bash on Windows

Is there a way to access removable media (e.g. thumb drives or SD cards) from within Bash on Windows? Bash on Windows uses DriveFs to mount fixed drives in the /mnt folder, but it doesn't ...
3
votes
1answer
2k views

Changing cursor shape in Windows Subsystem for Linux

Is there any way to change the cursor shape within Windows Subsystem for Linux terminal? I'd like my cursor to reflect the state I'm in in vim or vi-mode. In Git Bash for example I can use echo -ne "...
4
votes
1answer
2k views

Windows 10 Unix subsystem can't connect to the internet

I know there are other questions and even a Github issue about this, but I've tried all of the given answers and they don't work. These are the contents of the relevant files: /etc/hostname DESKTOP-...
2
votes
2answers
4k views

Bash doesn't work after Windows 10 update

Today I reset Windows 10. I first activated Windows a year ago. I recently created a bootable USB flash drive using Windows 10 Media Creation Tool (I have Windows 10 pro). After the installation I ...
10
votes
1answer
7k views

Bash on Windows / Windows Subsytem for Linux (WSL) not installing correctly / hangs

I got the windows anniversary update and tried to install Bash. I ran bash from the command prompt (non-admin mode) and it got stuck while trying to extract the files. I closed the window and tried to ...
1
vote
1answer
5k views

Windows 10 Ubuntu Bash: Aliases not working (: command not found)

I started the Ubuntu bash on Windows that was shipped with the Anniversary Update 1607. This bash sources the .bashrc file located at /home/phil which is the home directory of the Unix user, not the ...
8
votes
3answers
11k views

BASH on Ubuntu on Windows (AKA Linux Subsystem for Windows) 10 - How do I set my PATH?

Thanks to the Anniversary Update, I now have BASH on Ubuntu on Windows 10. Previously, I used Cygwin, and had set up Maven in Cygwin, (and got it fully working), which largely consisted of installing ...
0
votes
1answer
2k views

Windows Subsystem for Linux sources.list

Where is the sources.list file in Windows 10 version 1607 (Anniversary Update)? I can get it to it just fine from the cmd > bash > sudo nano /etc/apt/sources.list but I can't seem to find this file ...
28
votes
2answers
4k views

Where is the Ubuntu console on Windows10? [duplicate]

I updated my Windows 10 system to the 1607 "Anniversary Update" version and I can't find the Ubuntu Bash console. So... Where is it?
0
votes
1answer
2k views

How do I launch Bash for windows when I have cygwin installed?

I got the Windows 10 Anniversary update today and I'm excited to try the new Linux subsystem on windows. I previously have Cygwin installed on windows 10. So when I run bash from the command prompt, ...
10
votes
3answers
1k views

What causes strange CPU usage output of htop in Bash on Windows

When I run htop in Bash on Windows I get the following output regarding CPU usage: while the Windows Task Manager shows around 1% usage. From here it's clear that htop's red regions are supposed to ...
29
votes
3answers
16k views

UTF8 characters in windows 10 bash terminal

I have installed the new bash shell on windows 10. I'm using it together with ZSH. However, none of the utf8 characters work, they appear as square blocks. How do I enable utf8 character encoding in ...
0
votes
0answers
212 views

Regarding Bash and WIndows 10

so yesterday (August 2nd, 2016) Microsoft released their Anniversary Update which brought, among other things, a fully fledged bash shell to Windows. Here's what I am wondering, when we use the ...
0
votes
1answer
490 views

Windows 10 bash(ubuntu sub system)

Windows 10 bash (ubuntu sub system ) I have installed feature after anniversary update My question is what is bash as sub system ,how it works and apps like gcc ,g++ installed in bash(ubuntu sub) can ...
21
votes
2answers
13k views

sudo on Windows 10 Linux subsystem cannot resolve local machine name

I installed Windows 10 Anniversary update and the Linux subsystem. When running anything with sudo it takes ages and then I get this error message: sudo: unable to resolve host MYMACHINE How to ...
1
vote
1answer
678 views

Bash on Windows broke/stuck after moving an empty directory

After running the following commands (WARNING: dont run!) mkdir tmp1 mkdir tmp2 mv tmp1/ tmp2/ my Bash on Windows terminal got completely stuck while executing the mv command and wouldn't complete ...
14
votes
2answers
15k views

Can't ping in Bash on Windows

When I try to run: ping www.google.com I get the following error: ping: icmp open socket: Permission denied Running with sudo doesn't make a difference.
32
votes
4answers
13k views

How to disable Bash on Windows notification sound effect

When running 'Bash on Ubuntu on Windows' it often generates the Windows notification sound while typing. Common causes are when: I use auto-complete for commands (tab) and there are multiple command ...
73
votes
3answers
33k views

How do I change the language of the Linux subsystem in Windows 10 (WSL)?

After installing Bash in Windows 10 I noted that it is using Swedish in the linux applications. My Windows 10 installation is in English. I have tried to reinstall bash after changing the default ...
7
votes
3answers
17k views

How to sign into “root” account by default on Windows Subsystem for Linux Bash terminal

Windows 10's Anniversary Update just came out and I immediately installed the Windows Subsystem for Linux to see how it fares. I found only one major shortcoming so far: there was no obvious way to ...
39
votes
3answers
16k views

Where is the C drive in the WSL? [duplicate]

Whenever I try to login to bash using the Windows Subsystem for Linux, I try to cd into C:\Users\, but all I get is directory not found. Where is the C drive for the Windows Linux subsystem? Is it ...
5
votes
1answer
2k views

grub-pc update-error on Windows Linux Subsystem

After sudo apt upgrade following error constantly appears: $ sudo apt-get upgrade Reading package lists... Done Building dependency tree Reading state information... Done Calculating upgrade... Done ...
13
votes
6answers
11k views

Update Linux Subsystem on Windows (Ubuntu) to 16.04

Is there any possibility to update LXSS on Windows from 14.04 to 16.04? sudo do-release-upgrade does not work.
5
votes
2answers
5k views

Windows Bash vs Ubuntu in VM and the SSH

i have been looking around for some time, but i have not been able find out what the difference is between the new Bash For Windows 10 and a ssh into a Ubuntu running in a VM (With the windows drives ...
0
votes
0answers
457 views

Mulitple Ubuntu Subsystems on Windows 10

Is there any way to have multiple Linux Subsystems on Windows 10, each one separate from each other? Thanks
0
votes
4answers
212 views

Run Windows app from Ubuntu on Windows

I'm using bash on Ubuntu on Windows. I navigate to a folder and from there I'd like to open a file in a Windows program. For example: After entering cd \mnt\c\Users\myusername\Desktop notepad index....
9
votes
2answers
5k views

Can I get (the new) bash on Windows 10 to load .profile

I installed the Ubuntu (Bash) Linux on Windows 10 (which comes with the Windows anniversary update), and started playing around with it. What I noticed is that starting the shell (ubuntu bash) does ...
4
votes
2answers
9k views

Using WSL as a server

I recently got WSL installed, and after playing a bit was wondering about a couple things... first, is it possible to treat it as a server? For example, if I wanted to host a small mysql db- it looks ...
70
votes
4answers
64k views

Windows Linux Subsystem - Accessing Files outside of Ubuntu

Why, when I create a file from within Windows for example, can I not see it under the Linux sub system in Windows 10 (bash.exe) The screenshot should explain. Folder: OMG was created from within ...
7
votes
2answers
6k views

Is it possible to connect to the Subsystem for Linux in Windows 10 using SSH [duplicate]

Now that Windows 10 has the Windows Subsystem for Linux is it possible to connect to it remotely via SSH? With the Bash shell up and running I tried connecting Putty (running on the same Machine) to ...