Jump to content

Extract a docker volume from docker.img


Recommended Posts

So, for some reason I had to recreate my docker.img file, and I did that by also switching to folder instead of a docker image.

now I just realised that one of my compose files used a volume instead of persistent storage in a folder… quite stupid but it happened.

thankfully I did not delete the docker.img so I have a bit of hope to recover the data.

 

is there a way to extract the contents of a docker volume from the docker.img file? 
 

Link to comment

Should be possible, just everything in there is in folders named with nondescript hashes so you have to find the right one.

 

image.png.98d201b60f408546854287eb9a7a75ae.png

 

You'll want to do that on a linux system and save to a linux filesystem to preserve the file ownership/permissions.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...