Skip to content
Snippets Groups Projects
Commit 128fd4f7 authored by Bobi Jam's avatar Bobi Jam
Browse files

Branch b1_6

b=12888
i=johann, green

Description: mds_mfd_close() ASSERTION(rc == 0)
Details    : In mds_mfd_close(), we need protect inode's writecount change
             within its orphan write semaphore to prevent possible races.
parent 3521ec81
No related branches found
No related tags found
No related merge requests found
...@@ -25,11 +25,17 @@ tbd Sun Microsystems, Inc. ...@@ -25,11 +25,17 @@ tbd Sun Microsystems, Inc.
'tunefs.lustre --param="mdt.quota_type=ug1" $MDTDEV'. 'tunefs.lustre --param="mdt.quota_type=ug1" $MDTDEV'.
For more information, please refer to bugzilla 13904. For more information, please refer to bugzilla 13904.
Severity : normal
Bugzilla : 12888
Description: mds_mfd_close() ASSERTION(rc == 0)
Details : In mds_mfd_close(), we need protect inode's writecount change
within its orphan write semaphore to prevent possible races.
Severity : minor Severity : minor
Bugzilla : 14645 Bugzilla : 14645
Frequency : rare, on shutdown ost Frequency : rare, on shutdown ost
Description: don't hit live lock with umount ost. Description: don't hit live lock with umount ost.
Description: shrink_dcache_parent can be in long loop with destroy dentries, Details : shrink_dcache_parent can be in long loop with destroy dentries,
use shrink_dcache_sb instead. use shrink_dcache_sb instead.
Severity : minor Severity : minor
......
...@@ -1280,8 +1280,7 @@ int mds_mfd_close(struct ptlrpc_request *req, int offset, ...@@ -1280,8 +1280,7 @@ int mds_mfd_close(struct ptlrpc_request *req, int offset,
inode->i_nlink, mds_orphan_open_count(inode)); inode->i_nlink, mds_orphan_open_count(inode));
last_orphan = mds_orphan_open_dec_test(inode) && last_orphan = mds_orphan_open_dec_test(inode) &&
mds_inode_is_orphan(inode); mds_inode_is_orphan(inode);
MDS_UP_WRITE_ORPHAN_SEM(inode);
/* this is half of the actual "close" */ /* this is half of the actual "close" */
if (mfd->mfd_mode & FMODE_WRITE) { if (mfd->mfd_mode & FMODE_WRITE) {
...@@ -1290,6 +1289,9 @@ int mds_mfd_close(struct ptlrpc_request *req, int offset, ...@@ -1290,6 +1289,9 @@ int mds_mfd_close(struct ptlrpc_request *req, int offset,
} else if (mfd->mfd_mode & MDS_FMODE_EXEC) { } else if (mfd->mfd_mode & MDS_FMODE_EXEC) {
mds_allow_write_access(inode); mds_allow_write_access(inode);
} }
/* here writecount change also needs protection from orphan write sem.
* so drop orphan write sem after mds_put_write_access, bz 12888. */
MDS_UP_WRITE_ORPHAN_SEM(inode);
if (last_orphan && unlink_orphan) { if (last_orphan && unlink_orphan) {
int stripe_count = 0; int stripe_count = 0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment