Online migration runs for 24 hours, and fails. The command output might look as follows:
[root@vz4 ~]# pmigrate c 7215332 c --online 10.20.30.40 email@example.com's password: Connection to destination node (10.20.30.40) is successfully established Moving/copying CT#7215332 -> CT#7215332, ,  ... Checking external bind mounts Check cluster ID Source and target CT private resides on the same shared partition Checking license restrictions Check of requires kernel modules Checking CPT image version for online migration Checking capabilities for online migration Checking technologies Checking templates for CT Checking IP addresses on destination node Check target CT name: test-ct /usr/libexec/vzvmiter exited with code 5 can not prepare vm for CT#7215332 : /usr/libexec/vzvmiter exited with code 5 Iterative migration is not available write() : Broken pipe vzsock_send() return 5 Suspending CT#7215332 ... done Dumping CT#7215332 ... done Syncing dump file... done OfflineManagement CT#7215332 ... done Killing CT#7215332 ... done Umounting CT#7215332 ...
In the output above the following lines are especially significant:
/usr/libexec/vzvmiter exited with code 5 can not prepare vm for CT#7215332 : /usr/libexec/vzvmiter exited with code 5 Iterative migration is not available
The hardware node does not have a swap partition or the size is too small to store the memory related to container's processes:
~# free -mt total used free shared buffers cached Mem: 48157 43042 5115 0 4119 18839 -/+ buffers/cache: 20083 28074 Swap: 0 0 0 Total: 48157 43042 5115
During online migration container's RAM state is saved to node's swap memory in order to simplify moving CT's state to another node. If source or destination hosts have insufficient swap then the online migration might fail and hang till timeout (24 hours) is reached.
This design was considered for improvement in scope of the request PSBM-20622.
This design has been improved in scope of the request PSBM-20622, it is fixed in PCS 6.0 - Update 4. Please install all updates to ensure old design is not affecting your migration.
Alternatively to make migration possible you may add more swap to source and destination hosts. It shouldn't be less than memory limit of a container you are migrating.
You may follow Red Hat guide if you want to know how can you add more swap (both swap partition and swap file are fine.