Bug 1319380 - trash xlator : trash_unlink_mkdir_cbk() enters in an infinte loop which results segfault
Summary: trash xlator : trash_unlink_mkdir_cbk() enters in an infinte loop which resul...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: trash-xlator
Version: 3.7.11
Hardware: All
OS: All
medium
medium
Target Milestone: ---
Assignee: Anoop C S
QA Contact:
URL:
Whiteboard:
Depends On: 1318757
Blocks: glusterfs-3.7.12
TreeView+ depends on / blocked
 
Reported: 2016-03-19 06:31 UTC by Anoop C S
Modified: 2016-06-28 12:13 UTC (History)
4 users (show)

Fixed In Version: glusterfs-3.7.12
Doc Type: Bug Fix
Doc Text:
Clone Of: 1318757
Environment:
Last Closed: 2016-06-28 12:13:55 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Anoop C S 2016-03-19 06:31:59 UTC
+++ This bug was initially created as a clone of Bug #1318757 +++

Description of problem:

The trash_unlink_mkdir() ends up in infinte loop due to the mkdir failure during creation of directory hierarchy for deleted file path.This will result in segfault of the brick process
  
Version-Release number of selected component (if applicable):
mainline

How reproducible:
always

Actual results:
result in crash

Expected results:
should handle it gracefully

Additional info:
Above mentioned issue is reported in
https://build.gluster.org/job/rackspace-regression-2GB-triggered/19112/consoleFull

--- Additional comment from Vijay Bellur on 2016-03-17 23:11:50 IST ---

REVIEW: http://review.gluster.org/13771 (features/trash: Handle unexpected errors during mkdir) posted (#1) for review on master by Anoop C S (anoopcs)

--- Additional comment from Vijay Bellur on 2016-03-19 01:49:35 IST ---

COMMIT: http://review.gluster.org/13771 committed in master by Jeff Darcy (jdarcy) 
------
commit 7b8e82f80942b862f30d3fb72c7eecb23fcae226
Author: Anoop C S <anoopcs>
Date:   Thu Mar 17 22:44:12 2016 +0530

    features/trash: Handle unexpected errors during mkdir
    
    When expected directory hierarchy in not present in trash directory,
    trash translator tries to create it inside the same. Any errors from
    posix other than the expected ones should be handled properly during
    an internal mkdir call and logged accordingly explaining the reason
    for not moving the file to trash directory.
    
    Change-Id: I4e19637138ea4fb92f9301be372ac19542a6aed8
    BUG: 1318757
    Signed-off-by: Anoop C S <anoopcs>
    Reviewed-on: http://review.gluster.org/13771
    Smoke: Gluster Build System <jenkins.com>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    CentOS-regression: Gluster Build System <jenkins.com>
    Reviewed-by: jiffin tony Thottan <jthottan>

Comment 1 Vijay Bellur 2016-03-19 06:33:35 UTC
REVIEW: http://review.gluster.org/13783 (features/trash: Handle unexpected errors during mkdir) posted (#1) for review on release-3.7 by Anoop C S (anoopcs)

Comment 2 Mike McCune 2016-03-28 22:15:42 UTC
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions

Comment 3 Anoop C S 2016-05-03 13:03:48 UTC
Patch has not yet merged. Changing status back to POST.

Comment 4 Vijay Bellur 2016-05-03 13:09:59 UTC
COMMIT: http://review.gluster.org/13783 committed in release-3.7 by Pranith Kumar Karampuri (pkarampu) 
------
commit dd0133fd38232261521fb6a810b9bb6dde4cc5a4
Author: Anoop C S <anoopcs>
Date:   Thu Mar 17 22:44:12 2016 +0530

    features/trash: Handle unexpected errors during mkdir
    
    When expected directory hierarchy in not present in trash directory,
    trash translator tries to create it inside the same. Any errors from
    posix other than the expected ones should be handled properly during
    an internal mkdir call and logged accordingly explaining the reason
    for not moving the file to trash directory.
    
    >Change-Id: I4e19637138ea4fb92f9301be372ac19542a6aed8
    >BUG: 1318757
    >Reviewed-on: http://review.gluster.org/13771
    >Smoke: Gluster Build System <jenkins.com>
    >NetBSD-regression: NetBSD Build System <jenkins.org>
    >CentOS-regression: Gluster Build System <jenkins.com>
    >Reviewed-by: jiffin tony Thottan <jthottan>
    
    (cherry picked from commit 7b8e82f80942b862f30d3fb72c7eecb23fcae226)
    
    Change-Id: I8574f461a4e60491b359685deeadedfb9760366e
    BUG: 1319380
    Signed-off-by: Anoop C S <anoopcs>
    Reviewed-on: http://review.gluster.org/13783
    Smoke: Gluster Build System <jenkins.com>
    CentOS-regression: Gluster Build System <jenkins.com>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    Reviewed-by: jiffin tony Thottan <jthottan>

Comment 5 Kaushal 2016-06-28 12:13:55 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.7.12, please open a new bug report.

glusterfs-3.7.12 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] https://www.gluster.org/pipermail/gluster-devel/2016-June/049918.html
[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.