For Migration of a HP virtual machine from one host to another .
what is needed is :
1. Same network
2. Same name of the Virtual Switch should be configured on both hots .
3. Both servers should be connected physically to the same SAN
4. All the disks in the GUEST VM should be on SAN
5. All the disks should be zoneed to directly WWN of the GUEST VM . not to HOST .
when we have all this .
Setup a ssh authentication between both the hosts .
From HOST1
secsetup host2
And from HOST2
secsetup host1
NOw it is much simple
check the current status with the hpvmstatus command for the running VM .
#-> hpvmstatus
[Virtual Machines]
Virtual Machine Name VM # Type OS Type State #VCPUs #Devs #Nets Memory
==================== ===== ==== ======= ========= ====== ===== ===== =======
tavmva 1 SH HPUX On (OS) 4 2 2 10 GB
Then RUN the command hpvmmigrate .
[root@tahux1:/root]#
#-> hpvmmigrate -o -P tavmva -h tahux2
hpvmmigrate: Connected to target VSP using 'tahux2'
hpvmmigrate: WARNING (tavmva): Remote message: GUID service warning: The WWNs (0x50014C2000000000, 0x50014C2800000000) are in use by another vpar or VM. Data loss may occur if not changed.
hpvmmigrate: WARNING (tavmva): Remote message: GUID service warning: The WWNs (0x50014C2000000001, 0x50014C2800000001) are in use by another vpar or VM. Data loss may occur if not changed.
hpvmmigrate: Starting vPar/VM 'tavmva' on target VSP host 'tahux2'
(C) Copyright 2000 - 2012 Hewlett-Packard Development Company, L.P.
Creation of VM minor device 1
Device file = /var/opt/hpvm/uuids/912889d6-7d8a-11e1-8f00-ec9a746a1c22/vm_dev
guestStatsStartThread: Started guestStatsCollectLoop - thread = 6
allocating datalogger memory: FF800000-FF900000 (1024KB)
allocating firmware RAM (fff00000-100000000, 1024KB)
Starting event polling thread
Online migration initiated by source 'tahux1.upmraflatac.upm-kymmene.com' (10.96.34.100)
Target: online migration started with encryption algorithm AES-128-CBC.
hpvmmigrate: Init phase (step 5) - progress 0%
hpvmmigrate: Init phase completed successfully.
hpvmmigrate: Copy phase - progress 0%
hpvmmigrate: Copy phase - progress 100%
hpvmmigrate: Copy phase completed successfully.
hpvmmigrate: I/O quiesce phase (step 12) - progress 0%
hpvmmigrate: I/O quiesce phase completed successfully.
hpvmmigrate: Frozen phase (step 1) - progress 0%
hpvmmigrate: Frozen phase (step 4) - progress 86%
Target: transfer aborted by source
hpvmmigrate: ERROR (tavmva): Remote message: Target vPar or VM exited. Status 2.
hpvmmigrate: ERROR (tavmva): Remote message: Unable to start vPar/VM on target.
hpvmmigrate: ERROR (tavmva): Migration was aborted by timeout in Frozen phase step 4.
[root@tahux1:/root]#
So in this it was aborted . due to timeout .
we can check the logs also .
SYSLOG says .
Aug 16 09:20:37 tahux1 hpvmapp tavmva[4210]: Source: transfer aborted by 60 second timeout in Frozen phase step 4
Aug 16 09:20:43 tahux1 vmunix: hvsd: HPVM online migration failed, restarting guest on original host
VM GUEST SPECIFIC LOGS /var/opt/hpvm/guests/tavmva/log
Source: online migration started at Fri Aug 16 09:17:27 2013
Source: online migration started with encryption algorithm AES-128-CBC.
Source: copyPages returning early because of phase timeout
Source: transfer aborted by 60 second timeout in Frozen phase step 4
Source: online migration abort - severity 3, status 1012
So now it is clear the the issue is due to timeout of frozen phase .
so we will change that from default to 90 seconds .
#-> hpvmstatus -P tavmva -V | grep -i time
Graceful stop timeout : 30
Init phase timeout : 90 seconds
Copy phase timeout : Infinite
I/O quiesce phase timeout: 15 seconds
Frozen phase timeout : 60 seconds
[Boot-time Information]
[root@tahux1:/root]#
#-> hpvmmodify -P tavmva -x graceful_stop_timeout=60 -x migrate_frozen_phase_timeout=90
[root@tahux1:/root]#
#-> hpvmstatus -P tavmva -V | grep -i time
Graceful stop timeout : 60
Init phase timeout : 90 seconds
Copy phase timeout : Infinite
I/O quiesce phase timeout: 30 seconds
Frozen phase timeout : 90 seconds
[Boot-time Information]
[root@tahux1:/root]#
and then after that we run this again .
and the VM gets migrated successfully
hpvmmigrate: Frozen phase (step 4) - progress 81%hpvmmigrate: Frozen phase (step 4) -
progress 84%hpvmmigrate: Frozen phase (step 23) - progress 96%hpvmmigrate: Frozen phase (step 24) - progress 96%
Event: configuration file renamed to /var/opt/hpvm/uuids/912889d6-7d8a-11e1-8f00-ec9a746a1c22/vmm_config.current
hpvmmigrate: Frozen phase completed successfully.
hpvmmigrate: vPar/VM migrated successfully.
[root@tahux1:/var/adm/RFC]#
and the status of VM it shows like below .
on TAHUX1 source host .
Virtual Machine Name VM # Type OS Type State #VCPUs #Devs #Nets Memory
==================== ===== ==== ======= ========= ====== ===== ===== =======
tavmva 1 SH HPUX Off (NR) 4 2 2 10 GB
[root@tahux2:/root]#
#-> hpvmstatus
[Virtual Machines]
Virtual Machine Name VM # Type OS Type State #VCPUs #Devs #Nets Memory
==================== ===== ==== ======= ========= ====== ===== ===== =======
tavmtest 1 SH HPUX On (OS) 1 2 2 8 GB
tavmva 2 SH HPUX On (OS) 4 2 2 10 GB