[libvirt] [PATCH] Add new attribute writeout to <filesystem> element

Eric Blake eblake at redhat.com
Thu Dec 22 14:17:49 UTC 2011


On 12/22/2011 01:01 AM, Deepak C Shetty wrote:
>>> +      The filesystem block has an optional
>>> attribute<code>writeout='immediate'</code>
>>
>> <code>write</code>, and it's better to clarify it only supports
>> "immediate" currently.
> 
> So you are proposing to change the attribute name to write instead of
> writeout ?
> I wanted to keep it as writeout, since it matches with the qemu option
> also, will
>  be easier to locate/debug, no ?

No.  Just because qemu names a feature by a particular name does not
mean the libvirt XML must reflect that same name.  Libvirt is striving
for a hypervisor-agnostic description of what is happening (in this
case, what is happening is a change to the 'write' policy), not a blind
copy of the qemu command line option.

Perhaps 'write_policy=' makes more sense than 'write=', but it's longer.

More importantly, I think you're attaching the attribute to the wrong
XML element.  This belongs in the <driver> sub-element of <disk>,
alongside the <driver
cache='none|writeback|writethrough|directsync|unsafe'> attribute.  It is
not a characteristic of the <disk> as seen by the guest, so much as it
is an attribute of the <driver> used to control how the changes
requested by the guest are reflected back to the host.

-- 
Eric Blake   eblake at redhat.com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20111222/8f259e27/attachment-0001.sig>


More information about the libvir-list mailing list