I was migrating one container from machine to another and accidentally i found that there are two similar container ID on the two machines e.g. 101 on both machines. Migration does not allow migrating a container if the same ID on the other machine exists.
I followed the steps below to change CTID from 101 to 102:
[email protected]# vzctl chkpnt 101 –dumpfile /tmp/Dump.101
[email protected]# mv /etc/vz/conf/101.conf /etc/vz/conf/102.conf
[email protected]# mv /vz/private/101 /vz/private/102
[email protected]# mv /vz/root/101 /vz/root/102
[email protected]# vzctl restore 102 –dumpfile /tmp/Dump.101
That’s all, now I’ve changed the container ID of VM from 101 to 102.