我有一个有5个容器的docker环境,它们是通过docker compose组成的。现在只有在mac机器上,并且只有在某些时候(看起来完全随机的)这5个容器中的一个不能启动。
奇怪的是,docker ps说容器正在运行,我可以连接到它。容器内部是一个JBoss服务器,ps表示有一个运行JBoss的进程。但实际上,JBoss并未启动并运行。docker compose console中没有日志记录,并且无法访问JBoss。
还有一个问题是,如果发生这种情况,整个docker-compose过程将无法再正确取消。所有的容器都会关闭,也可以强制关闭JBoss容器。然后,码头机挂断。
我在网上找不到任何线索...请帮帮我!
发布于 2016-01-15 13:55:53
在容器中运行的进程似乎处于一种奇怪的状态。尝试在不提供宽限期的情况下杀死它,或者移除容器。
stop : Stop a container by sending SIGTERM and then SIGKILL after a
grace period
--help=false Print usage
-t, --time=10 Seconds to wait for stop before killing itkill : Kill a running container using SIGKILL or a specified signal
--help=false Print usage
-s, --signal="KILL" Signal to send to the containerrm : Remove one or more containers
-f, --force=false Force the removal of a running container (uses SIGKILL)
--help=false Print usage
-l, --link=false Remove the specified link
-v, --volumes=false Remove the volumes associated with the container此外,尝试检查容器的日志:
docker logs --follow <container_name or container_id>发布于 2016-02-24 22:31:57
在更新到docker v1.10之后,问题不再出现:)
https://stackoverflow.com/questions/34746877
复制相似问题