Docker 节点从工作节点晋升为管理节点后发生故障

Docker 节点从工作节点晋升为管理节点后发生故障

Docker Swarm由3个节点组成:

ID                            HOSTNAME          STATUS    AVAILABILITY   MANAGER STATUS   ENGINE VERSION
ec9gxe01ofk38xb3o6hg8xccv     docker-worker01   Ready     Active                          20.10.9
e9eoqfjqgfoj5i7bp83dqoyn6     docker-worker02   Ready     Active                          20.10.9
nbvdgqwbw03m7huj0cscw7whc *   server03          Ready     Active         Leader           20.10.9

当我尝试在管理节点中提升工作节点时,它以“Down”状态结束:

[root@server03 ~]# docker node promote docker-worker02
Node docker-worker02 promoted to a manager in the swarm.
[root@server03 ~]# docker node  ls
ID                            HOSTNAME          STATUS    AVAILABILITY   MANAGER STATUS   ENGINE VERSION
ec9gxe01ofk38xb3o6hg8xccv     docker-worker01   Ready     Active                          20.10.9
e9eoqfjqgfoj5i7bp83dqoyn6     docker-worker02   Down      Active                          20.10.9
nbvdgqwbw03m7huj0cscw7whc *   server03          Ready     Active         Leader           20.10.9

但是,找不到任何显示注释服务器错误的日志。

答案1

我必须让那个 Down 节点离开并重新加入集群。这有助于将状态恢复为 Ready。

IE:

来自docker-worker02,

docker swarm leave

然后

swarm join --token <token> <ip:port>

相关内容