Ubuntu Shell Winfows Folder

14.08.2019
Ubuntu Shell Winfows Folder 4,8/5 4448 votes
  1. Access Windows Files From Ubuntu Subsystem

I installed the bash on Ubuntu on Windows 10 - the insider preview edition. Windows terminals are however are sort of cumbersome to use if one is used to Ubuntu's terminal. I was wondering if there is a way to access the Ubuntu filesystem from Windows so that I can do the development in some other editor and run the code from Ubuntu-bash ?

In my windows 10 command prompt, when I need to set the drive to some network shared drive I just use net use V: //192.168.xxx.xxx/folder I added Bash on Ubuntu on Windows in my Windows 10,. How to Install Ubuntu Bash Shell on Windows 10. Ubuntu Linux in full speed, not in a VM. How to Install Ubuntu Bash Shell on Windows 10. Ubuntu Linux in full speed, not in a VM. It is not a docker either. ESX Virtualization. This bash shell is kind of tightened with W10 as you can access the underlying Windows file system to work on your. An Ubuntu user space and bash shell, running natively in a Windows 10 cmd.exe console! File for suitable upload to the Windows Store. That required me to use Microsoft Visual Studio to clone a sample application, edit a few dozen XML files, create a bunch of icon.png’s of various sizes, and so on.

samarsamar

3 Answers

Any terminal program that can open a Windows command prompt should be able to run bash (bash.exe launches the Windows Linux Subsytem), so you don't have to be stuck with command.exe.

Conemu (mentioned by @anotherfred) or Cmder are some of the fan favorites. You can also use Powershell if you like that.

You can access your Windows files from WSL at /mnt/c (and /mnt/d if you have a d: drive, etc). That works relatively well if you want to do command line stuff and still access the files using your favorite Windows editor.

You can see your WSL file system from Windows at:

though I wouldn't mess with it from within Windows.

/root would be under

Subsystem

and

/home would be under

These two are mounted separately so that they are not deleted when you remove WSL.

cgraniercgranier

Windows 10 versions released since the end of 2017 (including the Fall Creators Update and Windows Insiders Builds 17063+) supports multiple linux distributions running on the same machine. In consequence, WSL must store the root filesystem for each distribution in a different location.

Download game pc one piece

The root filesystem is not located anymore at

New location of the filesystem folders

Each linux distribution installed from the Windows Store stores the root filesystem in a different folder at

The <distro folder> vary from one distribution to the other. For instance, the following are the <distro folder> in my test computer:

  • Ubuntu 16.04 : CanonicalGroupLimited.Ubuntu16.04onWindows_79rhkp1fndgsc
  • Ubuntu 18.04 : CanonicalGroupLimited.Ubuntu18.04onWindows_79rhkp1fndgsc
  • Debian : TheDebianProject.DebianGNULinux_76v4gfsz19hv4
  • Kali linux: KaliLinux.54290C8133FEE_ey8k8hqnwqnmg

Access Windows Files From Ubuntu Subsystem

If you wanna access the root or the home filesystems, you must use the appropriated folders. For instance, to go to the folders for the KaliLinux, you must go to:

Obtaining the path using lxRunOffline

LxRunOffline is a tool to manage WSL linux distributions. It can be used to install or move a WSL distribution to any folder of your computer.

You can use lxRunOffline get-dir to obtain the path of the installation folder. The root is in the rootfs sub-folder.

Obtaining the path Programmatically

If you are interested, you can obtain the path using a program. The information about the installed distributions and their configuration is stored in the Windows Registry.

You can check the information using the regedit and the following path:

Ubuntu Shell Winfows Folder

There is all the configuration of the diverse distributions you have installed. For instance, You can use Powershell to obtain the information of the base path for the default distribution.

To check the filesystems for all your installed distributions, you can use Powershell too.

JaimeJaime

It's the other way round: bash is accessing the windows filesystem which you will find at /mnt/c. Your files are (should be) in your windows filesystem and you can edit them as normal.

If you simply dislike the terminal interface, try something like conemu (https://conemu.github.io/). It's a convenient and pretty interface for command shell, powershell or whatever shell you like.

anotherfredanotherfred

Not the answer you're looking for? Browse other questions tagged ubuntuterminalwindows-10windows-subsystem-for-linux or ask your own question.

Comments are closed.