-
-
Save ts-sz/8dbdf2f7550f26df2d35498f652ca026 to your computer and use it in GitHub Desktop.
Reset proxmox cluster
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash -xe | |
systemctl stop pvestatd.service | |
systemctl stop pvedaemon.service | |
systemctl stop pve-cluster.service | |
systemctl stop corosync | |
systemctl stop pve-cluster | |
sqlite3 /var/lib/pve-cluster/config.db "delete from tree where name = 'corosync.conf';" | |
pmxcfs -l | |
rm /etc/pve/corosync.conf | |
rm /etc/corosync/* | |
rm /var/lib/corosync/* | |
rm -rf /etc/pve/nodes/* | |
systemctl start pve-cluster | |
systemctl start corosync | |
systemctl start pve-cluster.service | |
systemctl start pvedaemon.service | |
systemctl start pvestatd.service |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
no idea why google indexed this instead of the upstream, just for notice, this is a comment copied from source:
DANGER: This will delete ALL of your container & virtual machine configurations, so unless you want to spend the next however long recreating everything, do not do this!
And here is a guide on how to recreate those config (with zero downtime) if you did this by accident:
/etc/pve/lxc
and/etc/pve/qemu-server
Check process list if you forget the id-name mapping of the virtual machine.
For linux containers, it's ok to create a inaccurate config and then use
pct console [id]
to get into the running container to get more info then update the config file.