简体   繁体   中英

Is docker swarm rearranges the services upon draining a node to other nodes?

I've got a Docker Swarm Stack. Three managers and two nodes, precisely. There're few services on one node (on that node only) which are working correctly, and I've got a zombie container on it, which couldn't be killed. I wanted to drain this node to prevent access to this "bad" container (which is working, just ain't responding to any command, it's a website container) and create a healthy one later. And I'm not sure if these services would be rearranged to the "healthy" node?

Presumably, docker system prune hasn't finished its work correctly, and now the system is in lock mode.

I'm using Moby Linux.

$ docker version
Client:
 Version:   17.12.0-ce
 API version:   1.35
 Go version:    go1.9.2
 Git commit:    c97c6d6
 Built: Wed Dec 27 20:05:03 2017
 OS/Arch:   linux/amd64

Server:
 Engine:
  Version:  17.12.0-ce
  API version:  1.35 (minimum version 1.12)
  Go version:   go1.9.2
  Git commit:   c97c6d6
  Built:    Wed Dec 27 20:12:30 2017
  OS/Arch:  linux/amd64
  Experimental: true

UDP1 : draining a node doesn't stop any containers or rearranges the services, at least not from the start. Basically, all services on that node continue to functioning. That's was the question of interest.

UPD2 : after rebooting it started to give errors about 'No such image was found...', it could be resolved by logging in to Docker hub again.

这是集群的原理,相同的Kubernetes,如果一个节点出现故障,只要存在主节点,它就应该重新排列所有容器到其他节点的分配。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM