[Bugs] [Bug 1369349] enable trash, then truncate a large file lead to glusterfsd segfault

bugzilla at redhat.com bugzilla at redhat.com
Fri Mar 24 01:56:04 UTC 2017


https://bugzilla.redhat.com/show_bug.cgi?id=1369349



--- Comment #8 from WuVT <wzmvincent at sina.com> ---
(In reply to Jiffin from comment #7)
> Sorry I didn't get this. Incase of truncate we need to copy the old
> (original file) to trash directory before performing the truncate. so I
> don't understand how rename will helpful here?
>  
> The change which I am talking as work around will only effect truncated
> files. For the deleted files it will work based on the limit which have
> set(trash-max-file-size).

Sorry for my poor English.
I misunderstood the meaning of trash truncate. I need to learn the function of
vfs->fops.
Another question, I tried to comment out truncate and ftruncate of trash-fops,
like this:
struct xlator_fops fops = {
        .unlink          = trash_unlink,
        // .truncate        = trash_truncate,
        // .ftruncate       = trash_ftruncate,
        .rmdir           = trash_rmdir,
        .mkdir           = trash_mkdir,
        .rename          = trash_rename,
};
Is there any bad effects by doing this?
I tested the recycle of samba-4.2.3, it seems like that the recycle dosn't deal
with truncated files.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=pPNaYSYjSs&a=cc_unsubscribe


More information about the Bugs mailing list