docker已满,所有inode都被使用

有很大的问题,我所有的inode似乎都被使用了。 我已经清理了所有未使用的卷清理所有容器和图像的命令 – >docker修剪

但似乎仍然充满:

Filesystem Inodes IUsed IFree IUse% Mounted on none 3200000 3198742 1258 100% / tmpfs 873942 16 873926 1% /dev tmpfs 873942 13 873929 1% /sys/fs/cgroup /dev/sda1 3200000 3198742 1258 100% /images shm 873942 1 873941 1% /dev/shm tmpfs 873942 1 873941 1% /sys/firmware 

docker信息

 Containers: 5 Running: 3 Paused: 0 Stopped: 2 Images: 23 Server Version: 17.06.1-ce Storage Driver: aufs Root Dir: /var/lib/docker/aufs Backing Filesystem: extfs Dirs: 53 Dirperm1 Supported: true Logging Driver: json-file Cgroup Driver: cgroupfs Plugins: Volume: local Network: bridge host macvlan null overlay Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog Swarm: inactive Runtimes: runc Default Runtime: runc Init Binary: docker-init containerd version: 6e23458c129b551d5c9871e5174f6b1b7f6d1170 runc version: 810190ceaa507aa2727d7ae6f4790c76ec150bd2 init version: 949e6fa Kernel Version: 3.16.0-4-amd64 Operating System: Debian GNU/Linux 8 (jessie) OSType: linux Architecture: x86_64 CPUs: 2 Total Memory: 6.668GiB Name: serveur-1 ID: CW7J:FJAH:S4GR:4CGD:ZRWI:EDBY:AYBX:H2SD:TWZO:STZU:GSCX:TRIC Docker Root Dir: /var/lib/docker Debug Mode (client): false Debug Mode (server): false Registry: https://index.docker.io/v1/ Experimental: false Insecure Registries: 127.0.0.0/8 Live Restore Enabled: false 

我认为唯一可以做到这一点的是我在这台机器上做的一个构build。 这个版本运行一个npm安装与许多文件。 这些文件可以留在服务器上吗? 有没有机会删除这些临时文件?

系统中是否有悬挂的卷? 如果您的卷有悬挂,则可能会填满磁盘空间。

列出所有悬挂的卷

 docker volume ls -q -f dangling=true 

删除所有悬空卷

 docker volume rm `docker volume ls -q -f dangling=true` 

发现错误,这似乎是Docker 17.06.1-ce错误。 这个版本似乎不正确的删除图像,并保持文件在/var/lib/docker/aufs/mnt/所以只需升级到新的docker版本,这将是罚款。 现在df给我看

 Filesystem 1K-blocks Used Available Use% Mounted on /dev/sda1 51558236 3821696 45595452 8% / udev 10240 0 10240 0% /dev tmpfs 1398308 57696 1340612 5% /run tmpfs 3495768 0 3495768 0% /dev/shm tmpfs 5120 0 5120 0% /run/lock tmpfs 3495768 0 3495768 0% /sys/fs/cgroup 

这个更好 :)