[Bugs] [Bug 1423385] Crash in index xlator because of race in inode_ctx_set and inode_ref
bugzilla at redhat.com
bugzilla at redhat.com
Mon Feb 20 12:25:33 UTC 2017
https://bugzilla.redhat.com/show_bug.cgi?id=1423385
--- Comment #4 from Worker Ant <bugzilla-bot at gluster.org> ---
COMMIT: https://review.gluster.org/16655 committed in release-3.10 by
Shyamsundar Ranganathan (srangana at redhat.com)
------
commit d10c5375b33520f36fd6acbd47b617d43f529ca2
Author: Poornima G <pgurusid at redhat.com>
Date: Wed Feb 15 11:18:31 2017 +0530
libglusterfs: Fix a crash due to race between inode_ctx_set and inode_ref
Issue:
Currently inode ref count is guarded by inode_table->lock, and
inode_ctx is guarded by inode->lock. With the new patch [1]
inode_ref was modified to change the inode_ctx to track the ref
count per xlator. Thus inode_ref performed under inode_table->lock
is modifying inode_ctx which has to be modified only under inode->lock
Solution:
When a inode is created, inode_ctx holder is allocated for all the xlators.
Hence in case of inode_ctx_set instead of using the first free index in
inode ctx holder, we can have predecided index for every xlator in the
graph.
Credits Pranith K <pkarampu at redhat.com>
[1] http://review.gluster.org/13736
> Reviewed-on: https://review.gluster.org/16622
> Smoke: Gluster Build System <jenkins at build.gluster.org>
> NetBSD-regression: NetBSD Build System <jenkins at build.gluster.org>
> Reviewed-by: Niels de Vos <ndevos at redhat.com>
> CentOS-regression: Gluster Build System <jenkins at build.gluster.org>
> Reviewed-by: Pranith Kumar Karampuri <pkarampu at redhat.com>
Change-Id: I1bfe111c211fcc4fcd761bba01dc87c4c69b5170
BUG: 1423385
Signed-off-by: Poornima G <pgurusid at redhat.com>
Reviewed-on: https://review.gluster.org/16655
NetBSD-regression: NetBSD Build System <jenkins at build.gluster.org>
Smoke: Gluster Build System <jenkins at build.gluster.org>
CentOS-regression: Gluster Build System <jenkins at build.gluster.org>
Reviewed-by: Shyamsundar Ranganathan <srangana at redhat.com>
--
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=OJSKrbYFiG&a=cc_unsubscribe
More information about the Bugs
mailing list