>>>>> " " == Chad Schwartz <cwslist@main.cornernet.com> writes:
> Kernel NFS. 2.4.0-test1-ac7 (or plain test1, for that matter.)
> add rule to /etc/exports to allow permissions to any currently
> mounted FS, and start kernel nfs. (Debian packaging, in this
> case.. /etc/init.d/nfs-kernel-server start.)
> mount that FS from the remote system you just added the export
> rule for.
> Unmount that FS from the remote system.
> remove the rule from /etc/exports.
> rerun exportfs -r.
> try to unmount the FS on the NFS server, that was the FS that
> was exported.
> Can't unmount the directory. Device busy.
The following patch will fix 3 nfsd bugs, amongst them, the one that
you're describing.
1) Oops in fh_unlock() due to premature clearing of fh_dentry.
2) Dentry leak in exp_rootfh().
3) Filehandle leak in NFSv3 rename code.
Cheers,
Trond
diff -u --recursive --new-file linux-2.3.99-pre10-3/fs/nfsd/nfsfh.c linux-2.3.99-pre10-3-nfsd/fs/nfsd/nfsfh.c
--- linux-2.3.99-pre10-3/fs/nfsd/nfsfh.c Sat May 20 21:19:41 2000
+++ linux-2.3.99-pre10-3-nfsd/fs/nfsd/nfsfh.c Thu May 25 15:53:27 2000
@@ -812,8 +812,8 @@
{
struct dentry * dentry = fhp->fh_dentry;
if (fhp->fh_dverified) {
- fhp->fh_dentry = NULL;
fh_unlock(fhp);
+ fhp->fh_dentry = NULL;
fhp->fh_dverified = 0;
dput(dentry);
nfsd_nr_put++;
diff -u --recursive --new-file linux-2.3.99-pre10-3-sunrpc/fs/nfsd/export.c linux-2.3.99-pre10-3-nfsd-1/fs/nfsd/export.c
--- linux-2.3.99-pre10-3-sunrpc/fs/nfsd/export.c Mon May 8 20:17:47 2000
+++ linux-2.3.99-pre10-3-nfsd-1/fs/nfsd/export.c Sun Jun 4 00:52:47 2000
@@ -436,7 +436,6 @@
err = 0;
memcpy(f, &fh.fh_handle, sizeof(struct knfsd_fh));
fh_put(&fh);
- return err;
out:
path_release(&nd);
diff -u --recursive --new-file linux-2.3.99-pre10-3-sunrpc/fs/nfsd/nfs3proc.c linux-2.3.99-pre10-3-nfsd-1/fs/nfsd/nfs3proc.c
--- linux-2.3.99-pre10-3-sunrpc/fs/nfsd/nfs3proc.c Fri Mar 10 08:31:43 2000
+++ linux-2.3.99-pre10-3-nfsd-1/fs/nfsd/nfs3proc.c Sat Jun 3 23:46:31 2000
@@ -658,7 +658,7 @@
PROC(mknod, mknod, create, fhandle2, RC_REPLBUFF),
PROC(remove, dirop, wccstat, fhandle, RC_REPLBUFF),
PROC(rmdir, dirop, wccstat, fhandle, RC_REPLBUFF),
- PROC(rename, rename, rename, fhandle, RC_REPLBUFF),
+ PROC(rename, rename, rename, fhandle2, RC_REPLBUFF),
PROC(link, link, link, fhandle2, RC_REPLBUFF),
PROC(readdir, readdir, readdir, fhandle, RC_NOCACHE),
PROC(readdirplus,readdirplus, readdir, fhandle, RC_NOCACHE),
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Wed Jun 07 2000 - 21:00:18 EST