+++ This bug was initially created as a clone of Bug #1379285 +++
Description of problem:
From the code inspection, have observed that there are fd ref leaks for few fd-based gfapi fops. 'glfs_resolve_fd' returns a fd (either existing or migrated) with an extra ref taken. This needs to be unref'ed at the end of the operation.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
--- Additional comment from Worker Ant on 2016-09-26 05:35:39 EDT ---
REVIEW: http://review.gluster.org/15573 (gfapi: Fix few fd ref leaks) posted (#1) for review on master by soumya k (email@example.com)
--- Additional comment from Worker Ant on 2016-09-27 02:43:38 EDT ---
COMMIT: http://review.gluster.org/15573 committed in master by Niels de Vos (firstname.lastname@example.org)
Author: Soumya Koduri <email@example.com>
Date: Mon Sep 26 14:54:27 2016 +0530
gfapi: Fix few fd ref leaks
From the code inspection, have observed that there are fd ref
leaks for few fd-based gfapi fops. 'glfs_resolve_fd' returns
a fd (either existing or migrated) with an extra ref taken.
This needs to be unref'ed at the end of the operation.
Signed-off-by: Soumya Koduri <firstname.lastname@example.org>
NetBSD-regression: NetBSD Build System <email@example.com>
CentOS-regression: Gluster Build System <firstname.lastname@example.org>
Reviewed-by: Niels de Vos <email@example.com>
Smoke: Gluster Build System <firstname.lastname@example.org>
Upstream mainline : http://review.gluster.org/15573
Upstream 3.8 : http://review.gluster.org/15585
downstream : https://code.engineering.redhat.com/gerrit/86107
Ran Basic sanity on ganesha and don't see any issues with fd leak.
Will have inputs from Samba and Qemu (users of libgfapi), if basic sanity works fine there , will move the BZ to verified.
Ran basic sanity including mount, unmount, IOs, share connect disconnects and did not see any issues with fd leak.
Tested RHGS 3.2.0 interim build ( glusterfs-3.8.4-5.el7rhgs ) with RHEL 7.3 with following components :
I could able to create VMs and ran I/O inside the VMs. All works good.
Note: I haven't tested for the memory footprint or fd leaks with gfapi
As there are no regressions seen on nfs-ganesha, samba and Qemu because of this patch, moving the BZ to verified.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.