Re: [patch] virt-convert add disk signature into virt-image format export

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Joey Boggs wrote:
>>   
>>> diff -r 58a909b4f71c virt-convert
>>> --- a/virt-convert	Mon Sep 22 11:32:11 2008 -0400
>>> +++ b/virt-convert	Wed Oct 01 17:12:45 2008 -0400
>>> @@ -64,6 +64,8 @@
>>>      opts.add_option("", "--os-variant", type="string", dest="os_variant",
>>>                        action="callback", callback=cli.check_before_store,
>>>                        help=("The OS variant for fully virtualized guests, e.g. 'fedora6', 'rhel5', 'solaris10', 'win2k', 'vista'"))
>>> +    opts.add_option("", "--checksum", action="store_true", dest="checksum",
>>> +                    help=("Generate a checksum for a virt-image guest"))
>>>      opts.add_option("", "--noapic", action="store_true", dest="noapic",
>>>          help=("Disables APIC for fully virtualized guest (overrides value in os-type/os-variant db)"), default=False)
>>>      opts.add_option("", "--noacpi", action="store_true", dest="noacpi",
>>> @@ -184,6 +186,9 @@
>>>  
>>>      unixname = vmdef.name.replace(" ", "-")
>>>  
>>> +    if options.checksum:
>>> +        vmdef.checksum = "yes"
>>> +
>>>     
>> Rather than use a string yes/no, why not just call
>> the variable 'use_checksum' and have it as a bool
>> value?
>>
>> We probably also want to add an option like 
>> checksum_type, since it really isn't a simple
>> yes/no option. If no type is specified, we can
>> just whatever we deem is a sensible default.
>> This can be worked out later though.
>>
>>   
> I'll make that change for use_checksum. Would that mean we're only 
> generating 1 checksum by default?

Hmm, good question. Maybe just do away with use_checksum. We can
have a value checksum_types, which is a list of strings. Then
we can define constants like CSUM_MD5, CSUM_SHA256, etc. One
of these can be CSUM_DEFAULT, which is up to the individual
conversion drivers. So if the list is empty, no csum, otherwise
generate a csum for every entry in the list.


_______________________________________________
et-mgmt-tools mailing list
et-mgmt-tools@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/et-mgmt-tools

[Index of Archives]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux