'docker ps' hangs forever after server res

2019-04-30 03:50发布

After server restart docker looks alive but all commands like docker ps hang forever until I press Ctrl+C. What can be wrong?

Docker version 1.12.6, build 7392c3b/1.12.6 Linux ip-10-0-1-124 4.4.10-22.54.amzn1.x86_64

标签: docker
1条回答
Luminary・发光体
2楼-- · 2019-04-30 04:19

It turned out instance had uptime for over a year, many application releases were installed, /var/lib/docker/devicemapper folder contained hundreds of items that apparently refer to older abandoned containers.

I saw the process of eternal reading all this data while dockerd -D command that runs docker interactively for debugging.

I removed /var/lib/docker and /var/run/docker and re-installed docker and containers on my box, the problem was resolved.

Feels like I need a script that would periodically remove obsolete items from docker internals.

查看更多
登录 后发表回答