[sheepdog] [PATCH] sheep: implement a correct detection of object cache pushing completion

Ing. Luca Lazzeroni - Trend Servizi Srl luca at gvnet.it
Sat Jul 27 15:08:34 CEST 2013


Il 26/07/2013 16:01, Hitoshi Mitake ha scritto:
> At Fri, 26 Jul 2013 15:41:28 +0200,
> Ing. Luca Lazzeroni - Trend Servizi Srl wrote:
>> Il 24/07/2013 12:46, Hitoshi Mitake ha scritto:
>>> Current implementation for pushing object cache would have a bug. In
>>> object_cache_push(), the variable oc->push_count is incremented in the
>>> loop of queuing work. This can produce a non deterministic bug when
>>> a sequence of scheduling like below happens:
>> Hi Hitoshi,
>> I've tried to apply the patch as you suggested, but it isn't applyable 
>> to sheepdog-stable since:
>>
>> object_cache.c:888:1: error: ‘struct object_cache’ has no member named 
>> ‘dirty_count’
>>
>> Maybe code needs some refactor for succesfuly back-port it to 0.6-stable..
> Hi Luca,
>
> I updated stable-0.6 for fixing the problem of object cache. Could you
> test the latest stable-0.6?
>
> Thanks,
> Hitoshi
Hi,
I've tested your patch in our production network.
Using my script, I've made 4 different backups of a VM generating high
I/O (rsync of about 100 GB of data) by using the pattern:

1) Suspend vm
2) Take snapshot via "collie vdi snapshot"
3) Resume vm
4) Copy snapshot to external storage via "qemu-img convert"

Everything worked without segfaults and, it seems, with better
performances than before.

Thank for your work,

Luca




More information about the sheepdog mailing list