[prev in list] [next in list] [prev in thread] [next in thread]
List: linux-nfs
Subject: [NFS] fh_lock again
From: "Wendy Cheng" <wendy.cheng () falconstor ! com>
Date: 2003-02-17 19:44:45
[Download RAW message or body]
On 2.4.19 kernel within nfsd_create():
there is a check to see whether the response file
handle has been verified:
if (!resfph->fh_dentry) {
fh_lock(fhp);
....
}
The inode semaphore withing the fh_lock() hangs one of
the nfsds while running a failover test (we're trying out a
high availability file server design). The client is doing a
"mkdir" request. Similar problems are also found in
"remove" and "rmdir" requests. All runs are under NFS
version 3.
Unlike the remove and rmdir where we added "fh_put"
after the nfsd_unlink() calls to make the hang go away,
the hang within the nfsd_create() makes me a little bit
uneasy. Not sure whether we do something wrong in
the failover logic or it is just simply a linux nfsd coding
oversight - could some nfsd gurus take a look (linux/open
source is a new thing to me). My question is, in simple
words, where should this inode semaphore (inode->i_sem)
get released ? Is this a nfs v3 coding oversight or the
semaphore is released somewhere in nfsd path that I don't
know about (found a fh_put in nfssvc_release_fhandle()
within nfsxdr.c but with xdr's extensive use of function pointers,
it is hard to figure out who uses it).
Any help would be greatly appreciated.
Wendy
[Attachment #3 (unknown)]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1141" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>On 2.4.19 kernel within nfsd_create():</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>there is a check to see whether the response file
</FONT></DIV>
<DIV><FONT face=Arial size=2>handle has been verified:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>if (!resfph->fh_dentry) {</FONT></DIV>
<DIV><FONT face=Arial size=2> fh_lock(fhp);</FONT></DIV>
<DIV><FONT face=Arial size=2> ....</FONT></DIV>
<DIV><FONT face=Arial size=2>}</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>The inode semaphore withing the fh_lock() hangs one
of</FONT></DIV>
<DIV><FONT face=Arial size=2>the nfsds while running a failover test (we're
trying out a </FONT></DIV>
<DIV><FONT face=Arial size=2>high </FONT><FONT face=Arial size=2>availability
file server design). The client is doing a </FONT></DIV>
<DIV><FONT face=Arial size=2>"mkdir" request. Similar problems are also found in
</FONT></DIV>
<DIV><FONT face=Arial size=2>"remove" and "rmdir" requests. All runs are under
NFS</FONT></DIV>
<DIV><FONT face=Arial size=2>version 3.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Unlike the remove and rmdir where we added "fh_put"
</FONT></DIV>
<DIV><FONT face=Arial size=2>after the nfsd_unlink() calls to make the hang go
away,</FONT></DIV>
<DIV><FONT face=Arial size=2>the hang within the nfsd_create() makes me a
little bit</FONT></DIV>
<DIV><FONT face=Arial size=2>uneasy. Not sure whether we do something wrong
in</FONT></DIV>
<DIV><FONT face=Arial size=2>the failover logic or it is just simply a
linux nfsd coding</FONT></DIV>
<DIV><FONT face=Arial size=2>oversight - could some nfsd gurus take a look
(linux/open</FONT></DIV>
<DIV><FONT face=Arial size=2>source is a new thing to me). My question is, in
simple</FONT></DIV>
<DIV><FONT face=Arial size=2>words, where should this inode semaphore
(inode->i_sem)</FONT></DIV>
<DIV><FONT face=Arial size=2>get released ? Is this a nfs v3 coding oversight or
the </FONT></DIV>
<DIV><FONT face=Arial size=2>semaphore is released somewhere in nfsd path that I
don't </FONT></DIV>
<DIV><FONT face=Arial size=2>know about (found a fh_put in
nfssvc_release_fhandle()</FONT></DIV>
<DIV><FONT face=Arial size=2>within nfsxdr.c but with xdr's extensive use of
function pointers,</FONT></DIV>
<DIV><FONT face=Arial size=2>it is hard to figure out who uses it).</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Any help would be greatly appreciated.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Wendy</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV></BODY></HTML>
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
NFS maillist - NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic