Persist /mnt/wsl mountpoints
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 33.7k
- Forks
- 1.8k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 116
Description
Is your feature request related to a problem? Please describe.
In WSL2, I'd like to be able to share my home directory between distros. So when Ubuntu (my main distro) comes up, it adds a symlink from /mnt/wsl/homeuser/ to /home/user, and when OpenSuse comes up, it also mounts from /mnt/wsl/homeuser/ to /home/user.
Describe the solution you'd like
I understand /mnt/wsl enables the sharing between distros but unfortunately /mnt/wsl uses tmpfs, so when wsl shutsdown you lose everything that was there.
Describe alternatives you've considered
I could host the files on my main distro (Ubuntu) and share from Ubuntu to /mnt/wsl/homeuser/, and when OpenSuse comes up, it does the opposite. Unfortunately, for that to occur, Ubuntu must come up first, and must stay up, consuming memory and cpu cycles.
Additional context
Initial request started at #5177. Also related to #689 and to a possible wsl --mount described in https://github.com/MicrosoftDocs/WSL/pull/824.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no implementation files, tests, or entry points. Start by reviewing related issues #5177 and #689 and the MicrosoftDocs proposal for the existing WSL mount design. Done would require a decided implementation that preserves /mnt/wsl mountpoint contents across shutdown and makes them available to multiple distros.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- operating-systems
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100