-
Notifications
You must be signed in to change notification settings - Fork 286
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Moving Docker wsl files #5829
Comments
I have exactly the same problem. |
It's probably a matter of moving the two WSL2 distros created by Docker Desktop (output of Using these instructions (or similar): microsoft/WSL#4320 (comment) wsl --export docker-desktop docker-desktop.tar
wsl --unregister docker-desktop
wsl --import docker-desktop X:\wslStore\ docker-desktop.tar --version 2 ⚠ I haven't tried these instructions myself, so be very careful. There's good chance they'll destroy your Docker Desktop installation... I'm just looking around to see if anyone has already figured out if and how this can be done (as I'm expecting to encounter disk-space issues at some point in the future). |
@thijsputman Thanks for this feedback. I managed to do exactly what you suggested, and that worked fine for me. When I first started Docker after moving those two WSL distros it gave me some errors. But after restarting my whole machine and starting Docker again it works fine now, even with the moved WSL distros. |
@haimat, thanks for the confirmation; it indeed appears to work just fine 🙂 Issued a |
This is working for me but then my ubuntu 18.04 start as root user instead of my personnal user. |
A small addition: It's sufficient to move the |
any news? |
Just linking the other relevant issue that was auto-closed a few days ago #3122 ... same problem, can confirm still happening for me as well. |
Hi @thijsputman I'm interested to know if the setup survived an update? I've successfully used this thread to set up my WSL2 distro and Docker on a different drive but am afraid to update Docker now :D |
Hey @Erokos, it survives updates of Docker Desktop just fine! The only thing that happens is that the (small) |
it worked perfectly for me across multiple updates, but just stopped working... it maybe has something to do with 3.0.0 ? |
Just updated to 3.0.0 and on my system it's still working as expected (with |
After I did:
I was getting the following error: I solved this issue after I've restarted docker TWICE. |
@al-yakubovich From the commands you listed, you forgot to run See https://dev.to/kimcuonthenet/move-docker-desktop-data-distro-out-of-system-drive-4cg2 |
Issues go stale after 90 days of inactivity. Prevent issues from auto-closing with an If this issue is safe to close now please do so. Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. |
/remove-lifecycle stale This would be very useful when running the system off a smaller drive and having a larger data drive (e.g. NVMe system drive, larger SSD/HDD for data). |
It'd be nice if this was officially supported, or at least officially documented. The GUI says under Resources that "You are using the WSL 2 backend, so resource limits are managed by Windows." It seems like, at least for |
Hey, thanks for saving my clogged C: drive! (1) list WSL stores: wsl -l -v They should be stopped after stopping docker desktop (3) wsl --export docker-desktop-data docker-desktop.tar (4) restart computer (just in case) ... docker desktop started without a glitch and my container is up and running with my named volume as before etc... |
Issues go stale after 90 days of inactivity. Prevent issues from auto-closing with an If this issue is safe to close now please do so. Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. |
Hi all, thanks for your answer. @IsisChameleon there is a little typo error on your command. I make this process in my side:
|
/remove-lifecycle stale Even if this won't be supported by official tooling it should at least be documented in the official documentation. |
Issues go stale after 90 days of inactivity. Prevent issues from auto-closing with an If this issue is safe to close now please do so. Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. |
/lifecycle frozen |
After some ASP.NET Core compose of containers started filling up my development computer quickly, I stood up a 3 TB NAS server sharing with SMB. I mapped a drive (N) to a new NAS share and after doing the shutdown, and export ran the following: wsl --import docker-desktop-data "N:\data" "N:\data\docker-desktop-data.tar" causes: I've tried looking at various permissions, but can't seem to get it to accept the new location, it creates an empty ext4.vhdx and stops. This puts me dead in the water as the files are too large for my development laptop that otherwise would have 12 Gb free. Any ideas on the work around? Thanks! |
Seems like the movement of the disk to another drive didn't survive a Docker Desktop upgrade. |
Expected behavior
docker starts
Actual behavior
docker does not start
Information
Due to space limitations, I am trying to move files in %APPDATA%\Local\Docker to another drive. Finding up-to-date information on how to do this is bewildering. So I tried adding "data-root": "D:\docker" to the config section of Settings > Docker Engine.
Steps to reproduce the behavior
The text was updated successfully, but these errors were encountered: