2)创建集群
先可以调成中文在点击添加集群

点击创建集群—》点击自定义
这里只修改两项:
集群名称:test1
网络驱动:选择flannel(也可以保持默认)
其他保持默认点击下一步
点击下一步
2)下一步主机选项
三个全选:etcd/control plane/worker
然后复制黑色框里的命令在需要部署的机器上执行即可
3)在需要部署的机器上执行
需要部署的节点为:node2
node2上运行
[rancher@node2 ~]$ sudo docker run -d --privileged --restart=unless-stopped --net=host -v /etc/kubernetes:/etc/kubernetes -v /var/run:/var/run rancher/rancher-agent:v2.3.3 --server https://192.168.216.51 --token ns6x6b2pc8lltbhjbjptqgx6bwcl52rd67px4kljrzdqzmk5h66xts --ca-checksum 72ff2101ce28276ebebc41386e4f7208349b16b0c8417a9ff589624451c03a9d --etcd --controlplane --worker Unable to find image 'rancher/rancher-agent:v2.3.3' locally v2.3.3: Pulling from rancher /rancher-agent 7ddbc47eeb70: Pull complete c1bbdc448b72: Pull complete 8c3b70e39044: Pull complete 45d437916d57: Pull complete 9d0628a9505a: Pull complete 86ff83498dc8: Pull complete 75a4645b34c1: Pull complete 24a0b57bdc62: Pull complete f4f0caf7fc9b: Pull complete e4f54def8dda: Pull complete Digest: sha256:ad0b39814ba3f6e1e5e16e1c2b46f02c8056298a45f5feacf833126f66fb3fd6 Status: Downloaded newer image for rancher /rancher-agent:v2.3.3 ef59b4f733e45f045110ee119836909531586ec5ab947ab96af515b496ce5a3b [rancher@node2 ~]$
部署需要等待一会
部署完成后会显示状态active
点击机器名称进入仪表盘