Unable to delete Node from Cluster

malgates

New Member
Jan 12, 2023
4
0
1
Hi everyone,

I added a 2nd node called pve2 to my cluster. Unfortunately I did a configuration error and I had to remove the 2nd node again. I followed the guide: https://pve.proxmox.com/wiki/Cluster_Manager#_remove_a_cluster_node

I was able to remove the node, but it is still there in the GUI.

When I am clicking on it I am getting the follwoing error:
hostname lookup 'pve2' failed - failed to get address info for: pve2: No address associated with hostname (500)

When I go to data center I am getting the follwoing error:
'/etc/pve/nodes/pve2/pve-ssl.pem' does not exist! (500)

Any ideas? THX
 
Last edited:
So "clusterkill.sh pve2" would do for you (if further problems reboot your 2 nodes after script usage) :
cat clusterkill.sh
#! /bin/bash

#############################################################################################
# Cluster reparieren durch Killen des Clusters und spaeteres Neuaufsetzen.
# 30.08.2024
# Quelle: https://gist.github.com/ianchen06/73acc392c72d6680099b7efac1351f56
#############################################################################################

if [ "$1" ]; then

echo -e "stopping Services:\npvestatd"
systemctl stop pvestatd.service
echo "pvedaemon"
systemctl stop pvedaemon.service
echo "pve-cluster.service"
systemctl stop pve-cluster.service
echo "pve-corosync"
systemctl stop corosync
echo "pve-cluster"
systemctl stop pve-cluster
###########################################################
#DB erstmal sichern
mkdir -p /root/pve-rep
cp -p /var/lib/pve-cluster/config.db /root/pve-rep/config.db_$(date -I)
###########################################################
echo "deleting data from db..."
#echo "select * from tree where name = 'corosync.conf';"| sqlite3 /var/lib/pve-cluster/config.db
echo "delete from tree where name = 'corosync.conf';"| sqlite3 /var/lib/pve-cluster/config.db
echo "select * from tree where name = 'corosync.conf';"| sqlite3 /var/lib/pve-cluster/config.db
#Remove directories
pmxcfs -l
rm -f /var/lib/pve-cluster/.pmxcfs.lockfile
rm -f /etc/pve/corosync.conf
rm -f /etc/corosync/*
rm -f /var/lib/corosync/*
rm -rf /etc/pve/nodes/$1/*
echo "Staring services ..."
echo "pvestatd"
systemctl start pvestatd.service
echo "pvedaemon"
systemctl start pvedaemon.service
echo "pve-cluster.service"
systemctl start pve-cluster.service
echo "pve-corosync"
systemctl start corosync
echo "pve-cluster"
systemctl restart pve-cluster
else
echo "Deleting node name missing or not existing. EXIT!"
exit
fi