Docker - Cannot remove dead container

后端 未结 20 1666
清歌不尽
清歌不尽 2020-12-22 16:28

I am unable to remove the dead container, it appears again after i restart the Docker service.

docker ps -a
CONTAINER ID         STATUS          
11667ef1623         


        
20条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-22 17:19

    You can also remove dead containers with this command

    docker rm $(docker ps --all -q -f status=dead)
    

    But, I'm really not sure why & how the dead containers are created. This error seems related https://github.com/typesafehub/mesos-spark-integration-tests/issues/34 whenever i get dead containers

    [Update] With Docker 1.13 update, we can easily remove both unwanted containers, dangling images

    $ docker system df #will show used space, similar to the unix tool df
    $ docker system prune # will remove all unused data.
    

提交回复
热议问题