Re: [Qemu-devel] qemu drive-mirror to rbd storage : no sparse rbd image

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

 



>>Just a wild guess - Alexandre, did you tried detect-zeroes blk option 
>>for mirroring targets? 

Hi, yes, I have also tried with detect-zeroes (on or discard) with virtio and virtio-scsi, doesn't help. (I'm not sure that is implemtend in drive-mirror).

As workaround currently, after drive-mirror, I doing fstrim inside the guest (with virtio-scsi + discard), 
and like this I can free space on rbd storage.



----- Mail original ----- 

De: "Andrey Korolyov" <andrey@xxxxxxx> 
À: "Fam Zheng" <famz@xxxxxxxxxx> 
Cc: "Alexandre DERUMIER" <aderumier@xxxxxxxxx>, "qemu-devel" <qemu-devel@xxxxxxxxxx>, "Ceph Devel" <ceph-devel@xxxxxxxxxxxxxxx> 
Envoyé: Samedi 11 Octobre 2014 10:30:40 
Objet: Re: [Qemu-devel] qemu drive-mirror to rbd storage : no sparse rbd image 

On Sat, Oct 11, 2014 at 12:25 PM, Fam Zheng <famz@xxxxxxxxxx> wrote: 
> On Sat, 10/11 10:00, Alexandre DERUMIER wrote: 
>> >>What is the source format? If the zero clusters are actually unallocated in the 
>> >>source image, drive-mirror will not write those clusters either. I.e. with 
>> >>"drive-mirror sync=top", both source and target should have the same "qemu-img 
>> >>map" output. 
>> 
>> Thanks for your reply, 
>> 
>> I had tried drive mirror (sync=full) with 
>> 
>> raw file (sparse) -> rbd (no sparse) 
>> rbd (sparse) -> rbd (no sparse) 
>> raw file (sparse) -> qcow2 on ext4 (sparse) 
>> rbd (sparse) -> raw on ext4 (sparse) 
>> 
>> Also I see that I have the same problem with target file format on xfs. 
>> 
>> raw file (sparse) -> qcow2 on xfs (no sparse) 
>> rbd (sparse) -> raw on xfs (no sparse) 
>> 
> 
> These don't tell me much. Maybe it's better to show the actual commands and how 
> you tell sparse from no sparse? 
> 
> Does "qcow2 -> qcow2" work for you on xfs? 
> 
>> 
>> I only have this problem with drive-mirror, qemu-img convert seem to simply skip zero blocks. 
>> 
>> 
>> Or maybe this is because I'm using sync=full ? 
>> 
>> What is the difference between full and top ? 
>> 
>> ""sync": what parts of the disk image should be copied to the destination; 
>> possibilities include "full" for all the disk, "top" for only the sectors 
>> allocated in the topmost image". 
>> 
>> (what is topmost image ?) 
> 
> For "sync=top", only the clusters allocated in the image itself is copied; for 
> "full", all those clusters allocated in the image itself, and its backing 
> image, and it's backing's backing image, ..., are copied. 
> 
> The image itself, having a backing image or not, is called the topmost image. 
> 
> Fam 
> -- 

Just a wild guess - Alexandre, did you tried detect-zeroes blk option 
for mirroring targets? 
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [CEPH Users]     [Ceph Large]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux