Skip to content

Using vzmigrate utility

The following should be done to migrate OpenVZ 6 container between OpenVZ 6 nodes using vzmigrate:

1. Install openssh-clients package:

yum install -y openssh-clients
2. Download a script for installation of SSH keys:
wget http://files.soluslabs.com/solusvm/scripts/keyput.sh
chmod a+x keyput.sh
3. Install SSH keys on the target server:
./keyput.sh destination_node_ip destination_node_sshport
4. Find VMID of the container for migration:
vzctl list
5. Migrate the container:
vzmigrate -v --ssh="-p destination_sshnode_port" destination_node_ip VMID
6. Update Master node database with the new location of VPS
/scripts/vm-migrate ID NEWNODEID
where ID - ID of the migrated VPS, can be seen in column ID in SolusVM > Virtual Servers; NEWNODEID - ID of the target node, can be seen in SolusVM > Nodes.
For example:
/scripts/vm-migrate 20 5

Back to top