无法移除闲置的docker容器.存储驱动程序:btrfs



我在移除死容器时遇到问题。当我试图移除容器时,我得到:

$ docker rm -f d1dd3082f7bb
Error response from daemon: Unable to remove filesystem for d1dd3082f7bbfc2310e497d0af47d51a8ca4e6e90a0d565a85d033f96a12325f: remove /var/lib/docker/containers/d1dd3082f7bbfc2310e497d0af47d51a8ca4e6e90a0d565a85d033f96a12325f/shm: device or resource busy

以前从未遇到过这样的问题。关于当前设置的一些信息:

$ uname -a
Linux AUIS1 3.16.6-2-default #1 SMP Mon Oct 20 13:47:22 UTC 2014 (feb42ea) x86_64 x86_64 x86_64 GNU/Linux
$ docker info
Containers: 19
Running: 15
 Paused: 0
 Stopped: 4
Images: 19
Server Version: 1.12.1
Storage Driver: btrfs
 Build Version: Btrfs v3.16+20140829
 Library Version: 101
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: overlay bridge null host
Swarm: inactive
Runtimes: oci runc
Default Runtime: oci
Security Options: apparmor
Kernel Version: 3.16.6-2-default
Operating System: openSUSE 13.2 (Harlequin) (x86_64)
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 15.66 GiB
Name: AUIS1
ID: PPHC:6VP2:PWW4:2JLX:I2UI:FZ3M:LWEQ:ZR6H:RV2K:HWRQ:VUCD:OPUH
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
WARNING: No swap limit support
WARNING: No kernel memory limit support
Cluster Store: consul://10.10.1.7:8500
Cluster Advertise: 10.10.1.7:2375
Insecure Registries:
 127.0.0.0/8

如何安全地移除它们?

忘了提一下,这些容器是由docker swarm和compose管理的。

$ docker ps -a
CONTAINER ID        IMAGE                                                 COMMAND                   CREATED             STATUS              PORTS                                                                                                                                                               NAMES
4a1193af7710        6ca7469301cb                                          "/bin/sh -c 'exec jav"    5 days ago          Dead                                                                                                                                                                                    4a1193af7710_4a1193af7710_4a1193af7710_xxxxxx2
f0446365fb75        e56d2658c291                                          "/bin/sh -c 'exec jav"    5 days ago          Dead                                                                                                                                                                                    f0446365fb75_f0446365fb75_f0446365fb75_f0446365fb75_xxxxx1
243e27c2cdf3        50e38ce0458f                                          "docker-entrypoint.sh"    6 days ago          Dead                                                                                                                                                                                    243e27c2cdf3_243e27c2cdf3_243e27c2cdf3_redis

增加了对死集装箱的码头检查,检查输出

$ docker inspect 4a1193af7710
grep d1dd3082f7bbfc2310e497d0af47d51a8ca4e6e90a0d565a85d033f96a12325f /proc/*/mountinfo

然后找到CCD_ 1的pid并杀死它

相关内容

  • 没有找到相关文章

最新更新