[Libvirt-cim] [PATCH 3 of 4] Add MigrationType support to VirtualSystemMigrationService

Kaitlin Rupert kaitlin at linux.vnet.ibm.com
Thu Feb 28 16:02:56 UTC 2008


Heidi Eckhart wrote:
> Kaitlin Rupert wrote:
>> Heidi Eckhart wrote:
>>> Is the type CIM_MIGRATE_LIVE or VIR_MIGRATE_LIVE ?
>> The CIM_MIGRATE_LIVE corresponds to the value defined in the mof, 
>> which is 2.  However, the value of VIR_MIGRATE_LIVE is defined by 
>> libvirt.
>>
>> So when someone specifies a migration type of 2 (CIM_MIGRATE_LIVE) in 
>> the MigrationSettingData, we'll need to use VIR_MIGRATE_LIVE when we 
>> call virDomainMigrate().
> Thanks for this explanation.
>>
>> For static migration, libvirt uses a value of 0. There's two type 
>> values here.. the value set for the MigrationType attribute of 
>> MigrationSettingData and the value libvirt uses to differentiate 
>> between static and live migration.
> ...
>> It is a little more redundant this way, but it might help with 
>> readability.
> 
> Thank you for this very good explanation. This makes now much more sense 
> to me :). But I think recoding as you suggested is not necessary, as it 
> would bring too much redundancy (as you already said) into the code. Now 
> that I understood it, I'm absolutely fine with it. Its not very 
> consistent that libvirt uses VIR_MIGRATE_LIVE and 0 (instead of 
> VIR_MIGRATE_STATIC or something else) as values, but that's something we 
> seem to live with.
> 

Yes, this confused me too as well.  =)  When I checked libvirt.h, I was 
surprised to see only one migration flag listed.  I wonder if this will 
change in the future?

-- 
Kaitlin Rupert
IBM Linux Technology Center
kaitlin at linux.vnet.ibm.com




More information about the Libvirt-cim mailing list