Proxmox VE 退出集群指令记录

由于PVE的集群机制需要两台宿主机在线运行,才可以启动虚拟机。

我的两台机器只是由于要迁移虚拟机才组成了集群。
两台PVE运行的服务彼此没有关联性,因此,集群也就没有保留的必要性,逐使其两者各自退出。

systemctl stop pve-cluster.service
systemctl stop corosync.service
pmxcfs -l
rm /etc/pve/corosync.conf
rm -rf /etc/corosync/*
killall pmxcfs
systemctl start pve-cluster.service

以上的命令请在shell中使用root执行。

原理为:停止PVE和集群的服务,并设置本机操作的宿主为「本地模式」,删除之前的集群配置文件和进程,再次启动单独的PVE服务。

另外,还需要删除本机以外的其他集群节点(Node),以便从Web UI中移除:

cd /etc/pve/nodes
rm -rf [本机之外的其他节点]

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

To respond on your own website, enter the URL of your response which should contain a link to this post's permalink URL. Your response will then appear (possibly after moderation) on this page. Want to update or remove your response? Update or delete your post and re-enter your post's URL again. (Find out more about Webmentions.)