Skip to content
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

Add progress to --export #5161

Open
KevinHake opened this issue Apr 30, 2020 · 11 comments
Open

Add progress to --export #5161

KevinHake opened this issue Apr 30, 2020 · 11 comments
Labels

Comments

@KevinHake
Copy link

Exporting a distro to a tar file with wsl.exe --export can take a long time, during which there is no feedback to the user. It would be nice to optionally see something like a progress bar, so the user knows the command is not stalled, and can estimate how much more time is needed to complete the task.

@thomasaull
Copy link

As a workaround, you can check how big the exported .tar file is and compare it with the size of your vhdx I guess?

@tautomer
Copy link

tautomer commented May 2, 2021

Another workaround is to check the disk usage and network usage (only when the backup is stored on a remote disk).
image

@b-hayes
Copy link

b-hayes commented Jul 19, 2021

The thing is mine appears like it should be finished with the tar file being 17gig, no disk usage etc but the export has not finished.
How can I reliably tell if it is finished and that the export is safe to re-use on another system? Any kind of feedback would be nice.

@EvidentlyCube
Copy link

Another reason to have ANY kind of feedback - my Win 11 broke overnight and I am preparing to reinstall the system and I don't know if the export is happening (in which case I'll wait for it to finish) or if it's just there happily doing nothing.

@agarwalvaibhav0211
Copy link

A much needed feature. My vhdx is 20gb, but the tar file shows zero mb size after waiting for 2 hours. When I cancel the command thinking the export is not working, the tar file suddenly becomes 15GB in size. Thus a progress bar would be a good feature

@gsusI
Copy link

gsusI commented Jun 4, 2022

A much needed feature. My vhdx is 20gb, but the tar file shows zero mb size after waiting for 2 hours. When I cancel the command thinking the export is not working, the tar file suddenly becomes 15GB in size. Thus a progress bar would be a good feature

This is exactly the issue I encountered, the tar file size is not updated until the process is killed or finished.

My WHDX is 75GB, so exporting becomes a painful process.

Also, errors can occur, so a process that doesn't give feedback for hours can become very frustrating.

Using the trick suggested by @tautomer helps as, at least, I can see that the export process is writing something.

@gsusI
Copy link

gsusI commented Jun 4, 2022

So... in terms of figuring out the size of the exported tar to understand the progress of the export process:

  • File explorer shows 0KB
    image

  • Powershell was showing 0KB, too
    image

But, when I ran WinDirStat for that folder... tachan!

image

Then, the even more interesting part, ls now shows the size

image

🤷‍♂️

@ezrag26
Copy link

ezrag26 commented Jun 13, 2022

As a workaround, you can check how big the exported .tar file is and compare it with the size of your vhdx I guess?

I wasn't able to see it update when refreshing the folder (which usually helps other times) but I was able to see it change after double clicking on the file, in case this helps anyone else.

@jepdavidson
Copy link

I know this is an old issue, but in case it helps anyone:

On Windows11, I also see 0 KB reported as the tar file size in Windows explorer. However, I found that right-clicking the file and choosing 'properties' from the context menu will show the file size.

image

The property window can be closed and the process repeated to monitor progress.

@eburnette
Copy link

Why is it so slow anyway? My docker-desktop-data vhdx is 642GB, and it's... taking... forever.... Task manager shows 12% CPU, and the C: drive (SSD) shows 142MB/s reads. I could have copied the vhdx file many times over by now (over an hour). I know there's a regedit workaround, but I'm wary of going that route.

@KevinHake
Copy link
Author

Why is it so slow anyway? My docker-desktop-data vhdx is 642GB, and it's... taking... forever.... Task manager shows 12% CPU, and the C: drive (SSD) shows 142MB/s reads.

Well, 642GB at 142MB/s is something like 75 minutes, and presumably you're writing the copy out to the same drive, so add to that the size / write speed (it'll depend on your hardware if/how much reading and writing can happen in parallel). Do you know how long it did take to finish?

For comparison, my big old spinning disk drive does a ~53MB/s copy of sequential data, and my 980 Pro SSD copying a big git repo (lots of randomly sized files) averages ~100MB/s (in native linux)... so an hour 50 minutes is right around what I'd expect on my SSD.

According to this: https://github.com/Microsoft/WSL/blob/master/CONTRIBUTING.md we have some tools available to get logs about what's happening when the command is issued, so that might make the solution (adding a progress bar) obvious (and might also make it more clear it's not stalled). Not sure if anyone with access to the code will see this, considering I opened it 4 years ago, but if someone wanted to post logs maybe it would help (I'm no longer using Windows, so it probably won't be me).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests