From 65d5d8df0e4aa7461b4122a56a2c1c98955475a6 Mon Sep 17 00:00:00 2001 From: name Date: Thu, 4 Jun 2020 21:23:16 +0000 Subject: [PATCH] Backup disk for later --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index c8dba59..68c4272 100644 --- a/README.md +++ b/README.md @@ -46,11 +46,29 @@ docker start $(docker ps -q --all --filter "ancestor=docker-osx") ``` +# Backup the disk + +your image will be stored in: + +/var/lib/docker/overlay2/...../arch/OSX-KVM/home/arch/OSX-KVM/mac_hdd_ng.img +``` +# find your container's root folder + +docker inspect $(docker ps -q --all --filter "ancestor=docker-osx") | grep UpperDir + +# In the folder from the above command, your image is inside ./home/arch/OSX-KVM/mac_hdd_ng.img + +# then sudo cp it somewhere. Don't do it while the container is running tho, it bugs out. + +``` + # Wipe old images ``` + # WARNING deletes all old images, but saves disk space if you make too many containers + docker system prune --all docker image prune --all