添加主机失败,提示主机状态Waiting for Node Ref

Rancher Server 设置

  • Rancher 版本:2.10
  • 安装选项 (Docker install/Helm Chart): Docker
  • 在线或离线部署:docker一键部署

用户信息

  • 登录用户的角色是什么?
    admin

主机操作系统:
centsos7.4

问题描述:
添加集群后,复制了注册命令执行后,无法成功。

使用sudo journalctl -u rancher-system-agent.service 查看日志显示以下信息

Failed at step EXEC spawning /usr/local/bin/rancher-system-agent: Text file busy
Dec 05 15:05:47 VM-20-4-centos systemd[1]: rancher-system-agent.service: main process exited, code=exited, status=203/EXEC
Dec 05 15:05:47 VM-20-4-centos systemd[1]: Unit rancher-system-agent.service entered failed state.
Dec 05 15:05:47 VM-20-4-centos systemd[1]: rancher-system-agent.service failed.
Dec 05 15:05:52 VM-20-4-centos systemd[1]: Stopped Rancher System Agent.
Dec 05 15:05:52 VM-20-4-centos systemd[1]: Started Rancher System Agent.
Dec 05 15:05:52 VM-20-4-centos rancher-system-agent[14969]: time="2024-12-05T15:05:52+08:00" level=info msg="Rancher System Agent version v0.3.11
Dec 05 15:05:52 VM-20-4-centos rancher-system-agent[14969]: time="2024-12-05T15:05:52+08:00" level=info msg="Using directory /var/lib/rancher/agen
Dec 05 15:05:52 VM-20-4-centos rancher-system-agent[14969]: time="2024-12-05T15:05:52+08:00" level=info msg="Starting remote watch of plans"
Dec 05 15:05:52 VM-20-4-centos rancher-system-agent[14969]: time="2024-12-05T15:05:52+08:00" level=info msg="Starting /v1, Kind=Secret controller"



点击本论坛右上角的 支持矩阵,替换成支持的操作系统再试试

系统更换为矩阵支持的系统 Ubuntu24.04 ,还是报错。

[INFO ] waiting for at least one control plane, etcd, and worker node to be registered
[INFO ] waiting for viable init node
[INFO ] configuring bootstrap node(s) custom-05e1044081a7: waiting for agent to check in and apply initial plan
[INFO ] configuring bootstrap node(s) custom-05e1044081a7: error applying plan -- check rancher-system-agent.service logs on node for more information, waiting for agent to check in and apply initial plan
[INFO ] configuring bootstrap node(s) custom-05e1044081a7: waiting for agent to check in and apply initial plan

我查看日志 journalctl -u rancher-system-agent.service,其中有docker镜像拉取失败的提示。

然后我在集群的镜像仓库配置了和registries.yaml一样的Mirror,再次查看rancher-system-agent.service日志后,一直提示探测CA证书

十有八九还是因为镜像没拉下来导致的,你配置的是哪个镜像仓库?

使用这个镜像地址,我主机的docker可以拉取rancher-images.txt里面所有的镜像。rancher容器也能拉取。

集群的网络配置这一块,我都是默认没有填写的

不能用最新版,使用v2.4.8才行

卧槽啊,昨天折腾了一整天,都放弃了。