[libvirt] Quorum block driver libvirt support proposal

Peter Krempa pkrempa at redhat.com
Fri May 16 14:07:35 UTC 2014


On 05/16/14 16:05, Benoît Canet wrote:
> The Friday 16 May 2014 à 09:54:43 (-0400), Daniel P. Berrange wrote :
>> On Fri, May 16, 2014 at 12:33:04PM +0200, Benoît Canet wrote:
>>>
>>> Hello list,                                                                     
>>>                                                                                 
>>> I want to implement libvirt Quorum support.                                     
>>> (https://github.com/qemu/qemu/commit/c88a1de51ab2f26a9a37ffc317249736de8c015c)  
>>> Quorum is a QEMU RAID like block storage driver.                                
>>> Data are written on n replicas and when a read is done a comparison between the 
>>> replica read is done. If more than threshold reads are identical the read succeed
>>> else it's and error.
>>>
>>> For example a Quorum with n = 3 and threshold = 2 would be made of three QCOW2
>>> backing chains used as identicals replicas. threshold = 2 means that at least
>>> 2 replica must be identical when doing a read.                                                            
>>>                                                                                 
>>> I want to make use of the new backingStore xml element to implement quorum.     
>>>                                                                                 
>>> Proposed Quorum libvirt format:                                                 
>>> -------------------------------                                                 
>>>                                                                                 
>>> <disk type='quorum' device='disk'>                                              
>>>   <driver name='qemu' type='quorum'/>                                           
>>>   <threshold value=2/>                                                          
>>>   <backingStore type='file'>                                                    
>>>     <format type='qcow2'/>                                                      
>>>     <source file='/var/lib/libvirt/images/file1.qcow2'/>                        
>>>   </backingStore>                                                               
>>>   <backingStore type='file'>                                                    
>>>     <format type='qcow2'/>                                                      
>>>     <source file='/var/lib/libvirt/images/file2.qcow2'/>                        
>>>   </backingStore>                                                               
>>>   <backingStore type='file'>                                                    
>>>     <format type='qcow2'/>                                                      
>>>     <source file='/var/lib/libvirt/images/file3.qcow2'/>                        
>>>   </backingStore>                                                               
>>>   <target dev='vda' bus='virtio'/>                                              
>>> </disk>
>>
>> It feels rather odd to have <backingStore> elements but no top level
>> disk images. Really these are all top level images
> 
> It reflect the ways QEMU does it. A single BlockDriverState holding n
> quorum BlockDriverState children. There is a 1-1 mapping.
> 
> How would you see it ?

We'd rather see multiple source elements for the top level disk. Backing
store is the property of the source image, thus every single of those
sources should have it's own list. (or perhaps a tree?)

> 
> Best regards
> 
> Benoît
> 
> 

Peter

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


More information about the libvir-list mailing list