Automated "renumbering" of VMIDs when adding a new node to a cluster ?

holgerb

Member
Aug 3, 2009
45
0
6
Hi there,

I did a quick search in the wiki but didn't find an answer to my question.

There we go:
If I use the automated numbering for VMs (-> VMID) and add a new node to a proxmox cluster which already has VMs on it, will proxmox be able to handle VMs with identical VMIDs ?

More specificially: I have a VM in my cluster with VMID=101 as well as a VM on the new node with VMID=101. Will promox renumber them automatically ? Or do I have to renumber the VMs manually on the new node before joining it to the cluster ?

If I have to renumber them manually my next question would be if it is possible to renumber without have to generate a new VM and manually copying over the qcow images ?

TIA,
Holger
 
If I use the automated numbering for VMs (-> VMID) and add a new node to a proxmox cluster which already has VMs on it, will proxmox be able to handle VMs with identical VMIDs ?

no - the idea is that IDs are unique.

More specificially: I have a VM in my cluster with VMID=101 as well as a VM on the new node with VMID=101. Will promox renumber them automatically ? Or do I have to renumber the VMs manually on the new node before joining it to the cluster ?

If I have to renumber them manually my next question would be if it is possible to renumber without have to generate a new VM and manually copying over the qcow images ?

You can rename the files manually, or use vzdump backup/restore to to that for you.
 
Thanks for answering !

You can rename the files manually, or use vzdump backup/restore to to that for you.
Ok, so "renumbering" a VM would include the following steps:
1) Rename the conf file for the VM under /etc/qemu-server (e.g. mv 101.conf 201.conf)
2) Rename the folder storing the corresponding HDD images under /var/lib/vz/images (e.g. move 101 201)

Am I missing something here ?

An option to edit the VMID via proxmox webinterface would be nice though.
 
What I do personally is number my VM's with the last 2 octets of that machines IP address which may or may not work for you depending on how static your network is...

Say for example, you have a webserver at 101.102.103.104, I would make it's VMID 103104...