Skip to main content

Questions tagged [windows-subsystem-for-linux]

Use this tag for questions relating to Windows Subsystem for Linux, the compatibility layer developed by Canonical and Microsoft to run Ubuntu programs natively in newer versions of Windows.

Filter by
Sorted by
Tagged with
573 votes
6 answers
1.1m views

Where is the Ubuntu file system root directory in Windows Subsystem for Linux and vice versa?

I have installed Ubuntu subsystem on Windows 10 (after enabling feature in settings), but where is the Ubuntu file system root directory located in the drive?
July's user avatar
  • 5,833
335 votes
7 answers
398k views

Reset the password in Ubuntu / Linux Bash in Windows

I have installed Linux Bash on Windows 10 (available from Microsoft), but I've forgotten my password. I've searched for a solution but I only find suggestions that involve doing something before the ...
Maheedhar K V's user avatar
216 votes
5 answers
377k views

WSL: Am I running version 1 or version 2?

I have Windows Subsystem for Linux, but I don't know which version I have, and many things won't work in version 1. How do I check my version?
K7AAY's user avatar
  • 17.3k
215 votes
3 answers
941k views

System has not been booted with systemd as init system (PID 1). Can't operate

I use WSL2 on Windows 11. I want to run the systemctl command in Ubuntu 20.04, but it gives me the following error: System has not been booted with systemd as init system (PID 1). Can't operate. ...
David SHainidze's user avatar
144 votes
10 answers
311k views

What's the easiest way to run GUI apps on Windows Subsystem for Linux?

I searched around, and currently there are two methods suggested; installing an enhancement for Windows Subsystem for Linux and installing an XServer. I want to know which method is the most hassle-...
George Hovhannisian's user avatar
113 votes
5 answers
266k views

Unable to change the root password in Windows 10 WSL

I have tried both commands sudo passwd and sudo -u root /bin/bash But as soon as I enter the new password twice, it says password has been updated. You close the shell and open a new instance, it ...
Dragonborn's user avatar
  • 1,233
96 votes
9 answers
216k views

How to change default user in WSL Ubuntu bash on Windows 10

I installed the WSL Bash on Windows 10 and set my user to e.g. 'abc' but now I want to change it to something else. How can I change the user name of the user I'm logged in as? When I open bash it ...
mlevit's user avatar
  • 1,069
90 votes
4 answers
126k views

WSL Ubuntu Distro | How to solve `Operation not permitted` on cloning repository

I am running Ubuntu 18.04, as a Subsystem for Windows. I have done this in mutliple PCs and never had this problem. I try to to git clone <repo>, and I get this: Cloning into '<repo>'... ...
Dimitris Efst's user avatar
90 votes
6 answers
243k views

How do I fix "$'\r': command not found" errors running Bash scripts in WSL?

I'm getting an error in WSL while trying to use junyanz/pytorch-CycleGAN-and-pix2pix. I followed all the install steps successfully on Windows 10 x64 using the steps at PyTORCH on Windows 10: An ...
Vincent Thomas's user avatar
88 votes
6 answers
160k views

Upgrade Ubuntu in WSL2 from 20.04 to 22.04

I'm new to WSL2-Ubuntu. My computer already had preisntalled the 20.04 version, but I saw there's already the 22.04 version, so I was wondering if it was worthy to have the new one. If so, how can I ...
alma_'s user avatar
  • 983
71 votes
3 answers
109k views

How can I send mobile text message from terminal?

I've just lost my phone. I know it's here in my house cause I used it last night and my bluetooth speakers will connect to it this morning. How can I text my phone using bash? Then the phone ...
WinEunuuchs2Unix's user avatar
71 votes
2 answers
51k views

What are the differences between Windows Bash and Cygwin?

What are the differences between Windows Bash and Cygwin? The new update from Windows with "Linux" Bash is new, but what differences are there to Cygwin that might make you choose one over the other?
Martijn van Wezel's user avatar
66 votes
9 answers
205k views

/usr/bin/env: ‘python’: No such file or directory

I am trying to install Gitlab Development Kit on Windows Ubuntu Bash. $python3 output Python 3.5.2 (default, Nov 17 2016, 17:05:23) [GCC 5.4.0 20160609] on linux Type "help", "copyright", "credits" ...
mertselimb's user avatar
60 votes
1 answer
246k views

How to navigate to C drive in bash on WSL-Ubuntu? [duplicate]

I've installed bash on Ubuntu on Windows feature on Windows 10 and I want to change directory this path on my C:\ drive: C:/wamp64/www What should I do ?
Dr. Doof's user avatar
  • 733
59 votes
5 answers
107k views

How do I reset my installation of Ubuntu on Windows?

I've installed Linux Subsystem for Windows on my machine. It works beautifully! Since then, I've done unspeakable things to my install. Nothing works anymore. How do I start again from scratch?
Carl Patenaude Poulin's user avatar
57 votes
8 answers
321k views

WSL 2 Won't Run Ubuntu - Error 0x80370102

Today, I decided to upgrade from WSL 1 to WSL 2. On WSL 1, I had no issues getting both Kali Linux or Ubuntu to function on WSL 1. When upgrading to WSL 2, both Kali and Ubuntu failed to upgrade to ...
Blu's user avatar
  • 671
54 votes
3 answers
116k views

How can I access my USB drive from my Windows Subsystem for Linux -- Ubuntu distribution?

How can I access my system's USB drive in Windows Subsystem for Linux (WSL)? I'm using an Ubuntu distribution.
Suhail Abdul Rehman Chougule's user avatar
54 votes
1 answer
50k views

Ubuntu 22.04 LTS on WSL: "Failed to retrieve available kernel versions"/"Failed to check for processor microcode upgrades" when installing packages

I just installed Ubuntu 22.04 LTS for Windows Subsystem for Linux, but I'm having some issues. Every time I install new packages using sudo apt install, I will get 2 messages saying that: Failed to ...
Liu Bei's user avatar
  • 741
53 votes
5 answers
114k views

Multiple terminal windows in Windows Ubuntu?

I am using Ubuntu downloaded from the Windows Store in Windows 10. It doesn't seem to be possible to use multiple terminal windows. Is the only way then to install a GUI and use this with the X server....
Sploxon's user avatar
  • 633
46 votes
4 answers
18k views

landscape-sysinfo.cache: Permission denied when I start Ubuntu 22.04 in WSL

I installed Ubuntu 22.04 on Windows 11 using WSL. I then moved it on another disk with the WSL commands (--export/--import). After moving it, the default user was root, so I added the below lines in /...
Sinedolo's user avatar
  • 623
45 votes
13 answers
118k views

Temporary Failure in name resolution on WSL

Running Ubuntu on WSL and trying to push to github and download new python modules using pip and I get this error. Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after ...
m_bash's user avatar
  • 551
45 votes
1 answer
21k views

Broken APT on WSL 18.04

I am having problems with apt on my WSL installation of Ubuntu 18.04. Whenever I try to install a package with apt I get this: Reading package lists... Done Building dependency tree Reading state ...
173467321476C's user avatar
43 votes
12 answers
58k views

A better terminal experience for Windows Subsystem for Linux(WSL)?

The terminal for Windows Subsystem for Linux (WSL) is fairly minimal. I have not used the terminal on Windows very much - I generally use Ubuntu or OSX - but I am surprised that the default terminal ...
David LeBauer's user avatar
40 votes
1 answer
156k views

Where is WSL located on my computer?

I am new to Windows and have installed WSL2 based on the instructions provided here. It works fine, but I cannot locate where it has been installed on my computer. The output for pwd is home/nkp68. ...
Krutik's user avatar
  • 511
39 votes
7 answers
202k views

Can I change directory to a Windows drive in Ubuntu Bash on WSL?

I am a super newbie for Ubuntu and basically need Ubuntu for a Python package. I would like to run a Python file in say e:/username/folder1/folder2/python.py. I tried every method online and the only ...
StephanieCoding's user avatar
34 votes
3 answers
87k views

Make /etc/resolv.conf changes permanent in WSL 2

On WSL 2, when I try to connect to a website, I get an issue: $ ping www.google.com ping: www.google.com: Temporary failure in name resolution Now, to fix this, I had to add /etc/wsl.conf with this ...
Olivier Grégoire's user avatar
33 votes
6 answers
30k views

Windows Subsystem for Linux (WSL): what can't I do with the Ubuntu application for Microsoft Windows?

As most of you know, in the Microsoft Store, there are three versions of Ubuntu. This means that on Windows I can emulate Ubuntu and have the Ubuntu command line directly on Windows. The question is ...
Leos313's user avatar
  • 1,946
31 votes
11 answers
117k views

DNS not working on WSL

I'm currently using an Insider build of Windows 11. (22458) However, I had this problem a few times on other builds. (and wsl worked before) When I start wsl, I'm not able to do a DNS request. (...
LightJack05's user avatar
30 votes
2 answers
102k views

New installation of Windows 10 and Ubuntu from Windows Store error

Please let me know if there is a more appropriate site to post this error. I have a brand new Dell i-7 Skylake laptop, brand new Samsung Pro 960 SSD, New Windows 10 build 16299 (Fall Creators Update ...
WinEunuuchs2Unix's user avatar
28 votes
4 answers
11k views

How does the new "Bash on Windows 10" really work?

I read online that Ubuntu and Bash are coming to Windows 10. I also read that it's not an emulator or virtual machine running on top of Windows, but something else. So how exactly does it all come ...
Maaverik's user avatar
  • 425
27 votes
1 answer
46k views

i am getting error on windows subsystem

when I switch to typing with bash on my windows laptop, it returns me an error like the one below, I searched a bit but couldn't find it and I'm very newbie, can you help me? this error : <3>WSL ...
Berkant's user avatar
  • 381
27 votes
4 answers
30k views

Ubuntu on Windows 10: Docker vs WSL

I understand that it is currently possible to run Ubuntu on Windows 10 in two different ways: Using the Windows Subsystem for Linux (WSL). Installing docker for Windows 10, and use a container with ...
alvgom's user avatar
  • 385
26 votes
7 answers
107k views

Can't restart/shutdown Ubuntu under WSL

I just got Ubuntu from Microsoft Store and tried some things with it. However when i try to restart or shut down the system using sudo reboot or sudo shutdown -h I got a prompt saying "System has ...
scotrod's user avatar
  • 361
24 votes
4 answers
144k views

Enable SSH in WSL system

I am trying to enable SSH in my Ubuntu running in WSL2 system: sudo systemctl status ssh I get this error: System has not been booted with systemd as init system (PID 1). Can't operate. Failed to ...
vico's user avatar
  • 4,597
23 votes
6 answers
26k views

Win10 linux subsystem libGL error: No matching fbConfigs or visuals found libGL error: failed to load driver: swrast

I'm not really asking a question, but this ___ website won't allow me to do this any other way. I ran into a problem today using GTK under Win10's Linux subsystem (specifically Ubuntu 18.04). The ...
Mike Maxwell's user avatar
23 votes
1 answer
27k views

How to upgrade Ubuntu packages in WSL alongside Microsoft Store auto-update

I started using WSL2 and installed Ubuntu from the Microsoft Store (the one without a specific version number). My understanding is that it will automatically upgrade to the next major LTS release -- ...
leoce's user avatar
  • 403
22 votes
5 answers
29k views

How can I get around using xclip in the Linux subsystem on Win 10?

On a Linux subsytem on Windows 10 you get an error when using xclip, ex: cat some/file.txt | xclip Error: Can't open display: (null) There is no Desktop (UI), so of course there isn't a clipboard to ...
givanse's user avatar
  • 571
22 votes
3 answers
50k views

Your system is unable to reach the snap store

I tried to upgrade my windows ubuntu subystem to 18.10 using this instruction: https://linuxconfig.org/how-to-upgrade-ubuntu-to-18-10-cosmic-cuttlefish#h9-how-to-upgrade-ubuntu-the-debian-way But ...
Zoker's user avatar
  • 333
22 votes
3 answers
50k views

How can I add ~/.local/bin to my PATH?

I'm just trying to follow this tutorial and set up my environment. My system is WSL Ubuntu 18.04. Here is already an answer on my question, but I as an absolute novice in Linux/UNIX don't know which ...
Alex's user avatar
  • 457
21 votes
5 answers
50k views

WSL not working after update from Microsoft store

Version Microsoft Windows [Version 10.0.19044.1586] WSL Version WSL 2 Kernel Version 5.10.16 Distro Version Ubuntu20.04LTS Other Software Docker Desktop (Windows), version 4.6.1 (76265) Docker Engine ...
J. Doe's user avatar
  • 319
21 votes
2 answers
29k views

How to start a specific service when Ubuntu is started on WSL2

I need to run sudo service postgresql start every time when I start Ubuntu on WSL2. How can I make the service start automatically when I start Ubuntu? WSL doesn't use systemd, so sudo systemctl ...
ironsand's user avatar
  • 1,137
20 votes
8 answers
30k views

sleep doesn't work on Ubuntu 20.04 (WSL)

After upgrading to 20.04 on WSL sleep doesn't work with an error: sleep: cannot read realtime clock: Invalid argument
Dmitriy Lyutov's user avatar
20 votes
4 answers
19k views

Why does it take so much time to initialize mlocate database?

While I was trying to install xubuntu-desktop on wsl2(Ubuntu 20.04) on windows 10. It got stuck at Initializing mlocate database; this may take some time... after waiting for a long time(left it for a ...
Aditya Patnaik's user avatar
18 votes
4 answers
21k views

Access Windows network shares from Ubuntu shell in WSL

I'm trying to migrate from Cygwin to WSL. In bash on Cygwin, I could do things like: $ ls //servername/sharename to access a Windows shared folder. I didn't need to mount it or anything first, it just ...
sprad's user avatar
  • 281
18 votes
1 answer
10k views

Does WSL2 run Linux in a virtual machine or alongside the Windows kernel?

I've always wanted a Linux terminal in Windows and was fulfilled by WSL 1. But it was painfully slow as it was (I guess) a Hyper-V-managed virtual machine. With WSL 2, it's way faster relatively but I ...
Sachin.Verma's user avatar
17 votes
4 answers
12k views

Running a simulation on pure Ubuntu vs on Ubuntu in Windows (WSL)

I would like to ask a question about testing a large CAE simulation on the same computer in the following two situations. Pure Ubuntu system Ubuntu system in Windows 10 (WSL) Are the calculation ...
ABCDEMMM's user avatar
  • 325
17 votes
3 answers
34k views

Connect MySQL Workbench to WSL2

I have a brand new WSL2, running on the latest Windows 10 (2004) with Ubuntu 20.04, MySQL installed, I can access it from Bash and get the status -- mysql> status -------------- mysql Ver 8.0.20-...
Jim Dunn's user avatar
  • 341
17 votes
3 answers
32k views

How to disable IPv6 on Windows Subsystem for Linux?

I tried to disable IPv6 by adding in /etc/sysctl.conf: net.ipv6.conf.all.disable_ipv6 = 1 net.ipv6.conf.default.disable_ipv6 = 1 net.ipv6.conf.lo.disable_ipv6 = 1 and then running sudo sysctl -p to ...
Răzvan Flavius Panda's user avatar
17 votes
2 answers
37k views

Windows 10 Bash "Cannot connect to display!"

I have recently installed Bash for Windows 10 (yay!). I need it to run my processing software called 'Seismic Unix' which installed fine. However, when I ran the command attached, it gave this error "...
maezawi's user avatar
  • 193
17 votes
4 answers
49k views

"Error: 0x80080005 Server execution failed" while installing Ubuntu on Windows

While installing Ubuntu app on Windows, I'm encountering this error: Installing, this may take a few minutes... WslRegisterDistribution failed with error: 0x80080005 Error: 0x80080005 Server ...
Pallav's user avatar
  • 171

1
2 3 4 5
28