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
Running out of space with many deployments #120
Comments
I'd like to know where that space is being used up first. They all use the On Thu, Jul 25, 2013 at 10:10 AM, Alexander Beletsky <
Jeff Lindsay |
I discovered the following sh scripts to be useful. I use them whenever I run out of memory. It happens quite often, if you deploy often. Those are created because of http://docs.docker.io/en/latest/use/workingwithrepository/ # delete all non-running container
docker ps -a | grep 'Exit' | awk '{print $1}' | xargs docker rm
# delete unused images
docker images | grep '<none>' | awk '{print $3}' | xargs docker rmi
# delete specific images
docker rmi app/example Should we run this stuff after every deploy? I was thinking about it. But how do we know that we do not kill other stuff running with docker? Especially if it was not deployed with dokku. |
@chris-rock Thanks, that's very useful. I'll try that on my existing machine.. In my opinion, it's safe to delete unused images, so it cold run as dokku step. |
Yes, in the short term perhaps it does an async cleanup triggered after On Thu, Jul 25, 2013 at 8:25 PM, Alexander Beletsky <
Jeff Lindsay |
It's very easy to reproduce, just try to do ~30 deploys, you will see a lot of unused images. I can clearly see that Heres how my server looks now.
After docker images | grep '<none>' | awk '{print $3}' | xargs docker rmi It looks
And a lot of space being freed up..
|
* cleanup: issue dokku#120 add step to clean up all dead instances and none used images check file exists before removing make reloader service start on reload Remove socket file before listening for reload
Ah so, my issue was an issue. Phew! |
issue #120 add step to clean up all dead instances and none used images
seems like #120 fixes this for now. On Fri, Jul 26, 2013 at 1:25 AM, James Brooks notifications@github.comwrote:
Jeff Lindsay |
yeah, sounds great. Good that my sh scrips are now build-in ;-) |
I currently see one cosmetic issue with that.. I haven't noticed initially, but it's also a good idea to redirect both |
Closing this as #121 got merged. |
issue dokku#120 add step to clean up all dead instances and none used images
I found this on google, so for anyone else who stumbles here, docker has a good article on how to fix this. Basically, the log files of the containers can get extremely big, in my case I had a 15G log file for a Dokku app! |
The situation mentioned in #119 is more critical then I thought.
I'm doing heavily testing of
dokku
running for my staging environment. I did maybe ~50 deployments today and by evening I recieved that:I checked out and indeed, my 20GB dropplet if full!
Running
docker images
I see a lot of images created. It shows size:24.81 kB (virtual 1.018 GB)
, for almost all images.This have to be mitigated some how. What I see:
As always, I'm ready to contribute the stuff, let's just agree on actual strategy.
(I would also add a question here: how can I quckly remove all
<none>
images :))The text was updated successfully, but these errors were encountered: