Re: release xlator_ckbs is not invoked?

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

 



Thanks Raghavendra, you answer helped me a lot. It works now.

Amin Abbaspour

On Wed, Jul 22, 2009 at 10:05 PM, Raghavendra G<raghavendra@xxxxxxxxxxx> wrote:
> Hi Amin,
>
> please find inlined comments.
>
> On Wed, Jul 22, 2009 at 3:47 PM, Amin Abbaspour <amin@xxxxxxxxxx> wrote:
>>
>> Hi All,
>>
>> This is my first post in the dev list :)
>>
>> I wrote a methods to be triggered during release callback and added it
>> to xlator_cbks struct in trace.c but this method is not invoked at
>> all.
>>
>> I can see that some other performance xlators such as write-behind and
>> read-ahead have similar callback handlers over release but but don't
>> know why my method is not called.
>>
>> Is there any other config required besides setting release variable in
>> xlator_cbks struct to my function pointer?
>>
>> I tried to set two others (releasedir and forget) but they are not
>> called either. I suppose editing a file in vim should call release at
>> the end. BTW my case is very similar to this issue in FUSE (
>> http://www.nabble.com/No-release-callback-after-cp-td23050110.html )
>> but I don't think there is any need for such a config in Gluster.
>
> You need to set some context related to trace in fd->ctx. Only xlators who
> have stored their contexts in fd, will have their cbks called. You can set
> context in fd from trace as,
>
> fd_ctx_set (this, fd, 1);
>
> Generally last argument will be a pointer to structure holding context of
> the translator. Here its just a dummy value.
>
>>
>>
>> Thanks for your help,
>> Regards,
>>
>> Amin Abbaspour
>>
>>
>> _______________________________________________
>> Gluster-devel mailing list
>> Gluster-devel@xxxxxxxxxx
>> http://lists.nongnu.org/mailman/listinfo/gluster-devel
>
>
>
> --
> Raghavendra G
>
>




[Index of Archives]     [Gluster Users]     [Ceph Users]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux