5 ms·
I'm very excited about the clean-up commands! Docker desperately needs this, it's so frustrating constantly having full disk space due to untagged containers a
by chrisfosterelli 10y ago
I'm very excited about the clean-up commands!
Docker desperately needs this, it's so frustrating constantly having full disk space due to untagged containers and unbounded volumes.
- geerlingguy 10y agoIf you're on Mac, it's still a bit of a problem; hopefully the SSD-gobbling Docker.qcow2 file problem[1] is fixed soon! [1] https://github.com/docker/for-mac/issues/371 https://github.com/docker/for-mac/issues/371
- selvakn 10y agoLooks like it is fixed in https://twitter.com/kelseyhightower/status/822237099495550976 https://twitter.com/kelseyhightower/status/82223709949555097.... Im looking for official changelog for confirmation though.
- iends 10y agoJudging by the github issue list there are a lot more issues with Docker.qcow2 now than before. Mostly related to Docker.qcow2 preventing docker from starting. Looks like a bad release. Hopefully 1.13.1 is soon.
- djs55 10y ago(I work on Docker for Mac.) Apologies for the inconvenience this has caused. There was a race condition in a previous release which could allow multiple hypervisor instances to open the Docker.qcow2 simultaneously. Unfortunately this can corrupt the file by allocating the same physical block (cluster) twice, resulting in bad things happening. When this file-locking bug was fixed we also added an integrity check which checks the structure of the Docker.qcow2 on every application launch. For safety the app refuses to start if corruption is detected. I believe that in these cases, the corruption happened in the past and is now being detected since the upgrade. Unfortunately if the app refuses to start it makes it difficult to reach the "Reset to Factory defaults" menu option. The workaround described here https://github.com/docker/for-mac/issues/1159#issuecomment-273899215 https://github.com/docker/for-mac/issues/1159#issuecomment-2... is to remove the qcow2 and restart the app. Unfortunately containers and images will need to be rebuilt. For what it's worth after the integrity check and the locking fix went in, I've not seen any recurrence of this error. Please open an issue if you see any other problems!
- justincormack 10y agoThis is now fixed on the stable release, but space is only released when you restart docker at present. Online freeing is being worked on too.
- dijit 10y agoI have a little one-liner I keep around on all my docker hosts that does this for me. I don't think you needed to wait for them to add anything. #!/usr/bin/env bash docker rmi $(docker images --filter "dangling=true" -q --no-trunc)
- alexellisuk 10y agoYes and isn't it fun to type that in over and over - especially on a new machine where you don't have your .dotfiles yet :-/ The new command is going to really save hassle here.
- nickjj 10y agoThe new command is definitely a nice addition, but I can't say that I've manually ran the other clean up commands in a long time. They were sitting in a daily cron for the last 9 months or so.
- ryan_lane 10y agoThe downside is the prune command is a giant hammer. In a lot of cases you don't want to clean everything, just things you know you won't be using. For instance, in a CI environment there's going to be some images that will always be there, but if you run a prune in-between jobs you've now made it necessary to re-pull all images.