Creating cluster with 5 nodes where many containers/VMs have same VMID/CTID

MikeC

Renowned Member
Jan 11, 2016
71
0
71
Bay Area, California
Hello. I have 5 separate nodes running now and I'm planning to create 1 cluster for all of them.
However, they each have VM/CT IDs starting at "100".

Will this present a problem, as far as ID conflicts, or will pvecm resolve these automagically?

If I have to change IDs on the 4 nodes I wish to add to the cluster, what's the best practice...and easiest way...to re-assign IDs for my mix of CTs and VMs?
There are more than 60 I'd have to change.
Is there a way to script changing the identifiers without having to backup/restore each of those many VMs/CTs?

Thanks.
 
Last edited:
Hello. I have 5 separate nodes running now and I'm planning to create 1 cluster for all of them.
However, they each have VM/CT IDs starting at "100".

Will this present a problem, as far as ID conflicts, or will pvecm resolve these automagically?
I thought the Proxmox manual stated that you should not add nodes to clusters when they have VMs/CTs already. Maybe you can migrate them (recent command-line feature) or backup/restore to the cluster with a new ID?
 
Thanks, Lee. Yeah, I saw that. I'll have to try this in a lab. Backing up and restoring everything is just untenable. The main issue I gleaned from the manual is that there might be "ID conflicts". My takeaway is that, if I have 1 node using IDs 100, 101, 102 and a second node having completely unique IDs, say 200, 201, 202, then that should mitigate the potential ID conflicts issue. As it turns out, you can change IDs easily. I tested creating a container that received the ID 112, then renamed the config in /etc/pve (112.conf to 412.conf since it's on the 4th node), and even relinked the device in /dev/pve to match the new CTID (I left the underlying block special device alone-this case /dev/dm-7 alone). The UI reflected the change and I was able to start the container with no problems.

The one part I need to research more is the case where the "nodes storage layout differs". For my local storage across all 5 of my nodes, disk devices are named "/dev/dm-x", where x appears to be sequential for each device created. Each of my 5 nodes starts with "dm-1". If a cluster of proxmox nodes changes that scheme, even though storage remains local to each node, then I'd have to discover how that naming occurs, and rename the raw devices across all nodes. I'll do this next in the lab and see what happens.
 
Last edited:
https://forum.proxmox.com/threads/node-with-existing-vms-joining-cluster.107066/

A node that is about to be added to the cluster cannot hold any guests. All existing configuration in /etc/pve is overwritten when joining a cluster, since guest IDs could otherwise conflict. As a workaround, you can create a backup of the guest (vzdump) and restore it under a different ID, after the node has been added to the cluster.[1]

https://pve.proxmox.com/wiki/Cluster_Manager#pvecm_join_node_to_cluster

You can try to trick the system you are installing

https://forum.proxmox.com/threads/joining-a-cluster-with-already-created-guests-vm.81064/

Google
https://www.google.com/search?q=proxmox+cluster+adding+new+node+with+existing+vm
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!