Bug 1377427 - incorrect fuse dumping for WRITE
Summary: incorrect fuse dumping for WRITE
Alias: None
Product: GlusterFS
Classification: Community
Component: fuse
Version: mainline
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Csaba Henk
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2016-09-19 16:07 UTC by Csaba Henk
Modified: 2017-03-06 17:26 UTC (History)
2 users (show)

Fixed In Version: glusterfs-3.10.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2017-03-06 17:26:53 UTC
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:

Attachments (Terms of Use)

Description Csaba Henk 2016-09-19 16:07:12 UTC
Description of problem:

glusterfs fuse client can record the fuse traffic with "--dump-fuse=<file>" option.
The payload of incoming FUSE_WRITE requests is incorrectly recorded.

Version-Release number of selected component (if applicable):

How reproducible:


Steps to Reproduce:

1. mount a GlusterFS volume through fuse with invoking glusterfs from command line, passing "--dump-fuse=/tmp/sample.fuse"
2. $ echo HELLO > /some/file/in/the/gluster/mount
3. umount the volume
4. get & build the parsefuse tool (https://github.com/csabahenk/parsefuse). The contrib/fuse-include/fuse_kernel.h file from the GlusterFS source tree (corresponding to the glusterfs binary used above) is needed for the build. Once you have it, follow the instrcuctions in the README.
5. $ parsefuse /tmp/sample.fuse | grep WRITE

Actual results:

WRITE {Len:86 Opcode:16 Unique:8 Nodeid:140114248345388 Uid:0 Gid:0 Pid:10162 Padding:0} {Fh:140114047011132 Offset:11275787851083 Size:0 WriteFlags:0 LockOwner:0 Flags:0 Padding:0} "\x00\x00\x00\x00\x00\x00"

Expected results:

WRITE {Len:86 Opcode:16 Unique:8 Nodeid:140467912052652 Uid:0 Gid:0 Pid:15076 Padding:0} {Fh:140467979165708 Offset:0 Size:6 WriteFlags:0 LockOwner:0 Flags:32769 Padding:0} "HELLO\n"

Additional info:

The WRITE payload is dumped 40 bytes off.

Comment 1 Worker Ant 2016-09-19 16:09:16 UTC
REVIEW: http://review.gluster.org/15525 (fuse: fix fuse dumping for FUSE_WRITE) posted (#2) for review on master by Csaba Henk (csaba@redhat.com)

Comment 2 Worker Ant 2016-09-23 05:34:08 UTC
COMMIT: http://review.gluster.org/15525 committed in master by Raghavendra G (rgowdapp@redhat.com) 
commit 3bfdcdcdfa04a12483a490fb6f766fd6689663a9
Author: Csaba Henk <csaba@redhat.com>
Date:   Mon Sep 19 03:58:15 2016 +0200

    fuse: fix fuse dumping for FUSE_WRITE
    Data coming with FUSE_WRITE requests are arranged
    with a special alignment, cf. 15d85ff1. fuse_dumper()
    was not aware of this and didn't dump the proper
    reqion for FUSE_WRITE.
    BUG: 1377427
    Signed-off-by: Csaba Henk <csaba@redhat.com>
    Change-Id: I36255ca3336e95be6e2d256c8199761ddec41869
    Reviewed-on: http://review.gluster.org/15525
    Smoke: Gluster Build System <jenkins@build.gluster.org>
    Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
    Tested-by: Raghavendra G <rgowdapp@redhat.com>
    CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
    NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>

Comment 3 Shyamsundar 2017-03-06 17:26:53 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.10.0, please open a new bug report.

glusterfs-3.10.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://lists.gluster.org/pipermail/gluster-users/2017-February/030119.html
[2] https://www.gluster.org/pipermail/gluster-users/

Note You need to log in before you can comment on or make changes to this bug.