Bug 1128801 - Memory leak when a large directory structure is created and deleted
Summary: Memory leak when a large directory structure is created and deleted
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: replicate
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Pranith Kumar K
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-08-11 14:52 UTC by Pranith Kumar K
Modified: 2014-11-11 08:37 UTC (History)
2 users (show)

Fixed In Version: glusterfs-3.6.0beta1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-11-11 08:37:17 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)

Description Pranith Kumar K 2014-08-11 14:52:29 UTC
Description of problem:
Create a big directory hierarchy and delete it. We find lots of 'dict' data structures leaking in the statedump

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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Anand Avati 2014-08-11 14:56:10 UTC
REVIEW: http://review.gluster.org/8457 (cluster/afr: Fix mem-leak) posted (#1) for review on master by Pranith Kumar Karampuri (pkarampu@redhat.com)

Comment 2 Anand Avati 2014-08-12 05:22:33 UTC
COMMIT: http://review.gluster.org/8457 committed in master by Anand Avati (avati@redhat.com) 
------
commit a66a483be2febd36e6cb338c9fe73d332257d89e
Author: Pranith Kumar K <pkarampu@redhat.com>
Date:   Mon Aug 11 20:22:53 2014 +0530

    cluster/afr: Fix mem-leak
    
    Problem:
    local->xattr_req is already reffed with xattr_req that comes
    in lookup fop. But when afr_lookup_xattr_req_prepare is called
    local->xattr_req is over-written with dict_new() which leads
    to ref leak on the dict which came in lookup fop
    
    Fix:
    Create local->xattr_req only when it is NULL
    
    Change-Id: Ib1548f2df97688859f2cace44b93b3b733297c36
    BUG: 1128801
    Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
    Reviewed-on: http://review.gluster.org/8457
    Tested-by: Gluster Build System <jenkins@build.gluster.com>
    Reviewed-by: Anand Avati <avati@redhat.com>

Comment 3 Anand Avati 2014-08-12 06:45:59 UTC
REVIEW: http://review.gluster.org/8460 (cluster/afr: Fix mem-leak) posted (#1) for review on release-3.6 by Pranith Kumar Karampuri (pkarampu@redhat.com)

Comment 4 Anand Avati 2014-08-13 08:43:15 UTC
REVIEW: http://review.gluster.org/8475 (cluster/afr: Fix mem-leak) posted (#1) for review on dht-stale-layout-fixes by Raghavendra G (rgowdapp@redhat.com)

Comment 5 Anand Avati 2014-08-20 06:38:57 UTC
COMMIT: http://review.gluster.org/8460 committed in release-3.6 by Vijay Bellur (vbellur@redhat.com) 
------
commit e8105af16c58f8c01be9b7d58b414da4391c86d6
Author: Pranith Kumar K <pkarampu@redhat.com>
Date:   Mon Aug 11 20:22:53 2014 +0530

    cluster/afr: Fix mem-leak
    
            Backport of http://review.gluster.org/8457
    
    Problem:
    local->xattr_req is already reffed with xattr_req that comes
    in lookup fop. But when afr_lookup_xattr_req_prepare is called
    local->xattr_req is over-written with dict_new() which leads
    to ref leak on the dict which came in lookup fop
    
    Fix:
    Create local->xattr_req only when it is NULL
    
    BUG: 1128801
    Change-Id: I4a1065add7700317e0cd3d0dda0a91e12d77e340
    Reviewed-on: http://review.gluster.org/8460
    Tested-by: Gluster Build System <jenkins@build.gluster.com>
    Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com>
    Reviewed-by: Vijay Bellur <vbellur@redhat.com>

Comment 6 Niels de Vos 2014-09-22 12:45:01 UTC
A beta release for GlusterFS 3.6.0 has been released. Please verify if the release solves this bug report for you. In case the glusterfs-3.6.0beta1 release does not have a resolution for this issue, leave a comment in this bug and move the status to ASSIGNED. If this release fixes the problem for you, leave a note and change the status to VERIFIED.

Packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update (possibly an "updates-testing" repository) infrastructure for your distribution.

[1] http://supercolony.gluster.org/pipermail/gluster-users/2014-September/018836.html
[2] http://supercolony.gluster.org/pipermail/gluster-users/

Comment 7 Niels de Vos 2014-11-11 08:37:17 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.6.1, please reopen this bug report.

glusterfs-3.6.1 has been announced [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://supercolony.gluster.org/pipermail/gluster-users/2014-November/019410.html
[2] http://supercolony.gluster.org/mailman/listinfo/gluster-users


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