Bug 1284365 - Sharding - Extending writes filling incorrect final size in postbuf
Sharding - Extending writes filling incorrect final size in postbuf
Status: CLOSED CURRENTRELEASE
Product: GlusterFS
Classification: Community
Component: sharding (Show other bugs)
mainline
Unspecified Unspecified
medium Severity high
: ---
: ---
Assigned To: Krutika Dhananjay
bugs@gluster.org
: Triaged
Depends On:
Blocks: 1285139
  Show dependency treegraph
 
Reported: 2015-11-23 02:32 EST by Krutika Dhananjay
Modified: 2016-06-16 09:46 EDT (History)
1 user (show)

See Also:
Fixed In Version: glusterfs-3.8rc2
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1285139 (view as bug list)
Environment:
Last Closed: 2016-06-16 09:46:08 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Krutika Dhananjay 2015-11-23 02:32:13 EST
Description of problem:
After an extending write is complete, at the level of shard translator, the postbuf is updated not once but twice with the same delta size and block count:
once in shard_update_file_size_cbk(), and
once in shard_post_update_size_writev_handler()

This can lead to unexpected behavior is md-cache is part of the client stack and caches these values returned by shard translator in postbuf.

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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:
Comment 1 Vijay Bellur 2015-11-23 02:42:36 EST
REVIEW: http://review.gluster.org/12717 (features/shard: Eliminate extra update to postbuf in writev) posted (#1) for review on master by Krutika Dhananjay (kdhananj@redhat.com)
Comment 2 Vijay Bellur 2015-11-23 07:38:35 EST
REVIEW: http://review.gluster.org/12717 (features/shard: Eliminate extra update to postbuf in writev) posted (#2) for review on master by Krutika Dhananjay (kdhananj@redhat.com)
Comment 3 Vijay Bellur 2015-11-23 13:58:10 EST
REVIEW: http://review.gluster.org/12717 (features/shard: Eliminate extra update to postbuf in writev) posted (#3) for review on master by Vijay Bellur (vbellur@redhat.com)
Comment 4 Vijay Bellur 2015-11-24 01:20:06 EST
COMMIT: http://review.gluster.org/12717 committed in master by Pranith Kumar Karampuri (pkarampu@redhat.com) 
------
commit c93e436527e9d2ceed46b939e18edc40b7018cee
Author: Krutika Dhananjay <kdhananj@redhat.com>
Date:   Mon Nov 23 13:06:25 2015 +0530

    features/shard: Eliminate extra update to postbuf in writev
    
    After an extending write is complete, shard translator updates postbuf
    at two places:
    1. shard_update_file_size_cbk(), and
    2. shard_post_update_size_writev_handler().
    
    This can lead to unexpected behavior if md-cache is part of the client
    stack and caches and serves values returned by shard translator in
    postbuf. This patch eliminates the update to postbuf in
    shard_post_update_size_writev_handler().
    
    Change-Id: I9d107bf57baad66886eebec14aa369b6a3c88c49
    BUG: 1284365
    Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com>
    Reviewed-on: http://review.gluster.org/12717
    Tested-by: NetBSD Build System <jenkins@build.gluster.org>
    Tested-by: Gluster Build System <jenkins@build.gluster.com>
    Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Comment 5 Niels de Vos 2016-06-16 09:46:08 EDT
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.8.0, please open a new bug report.

glusterfs-3.8.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://blog.gluster.org/2016/06/glusterfs-3-8-released/
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user

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