Linux NFS development
 help / color / mirror / Atom feed
From: Gu Zheng <guzheng1@huawei.com>
To: <bfields@fieldses.org>, <jlayton@poochiereds.net>
Cc: <linux-nfs@vger.kernel.org>, <houtao1@huawei.com>,
	Zhaohongjiang <zhaohongjiang@huawei.com>, <miaoxie@huawei.com>
Subject: nfs+ext4,can not umount the ext4 mountpoint
Date: Tue, 16 May 2017 20:57:03 +0800	[thread overview]
Message-ID: <591AF71F.1040703@huawei.com> (raw)

Hi all:
we have a test about nfs on linux 4.11.
the detailed process as follow:
server ip:9.81.231.141                    		client
mount -t ext4 /dev/vdb /home/nfs/aa
							mount -t nfs -o sync,tcp,vers=3,noac,timeo=70,retrans=3 9.81.231.141:/home/nfs  /tmp/aa/
							ls /tmp/aa
umount /home/nfs/aa

the umount remind "target is busy".
so we analyze the code , a reference count which is named "mnt_count" add 1 in rqst_exp_get_by_name() after execute the "ls" order.
the detailed call is nfsd3_proc_lookup->nfsd_lookup->nfsd_lookup_dentry->nfsd_cross_mnt->rqst_exp_get_by_name->exp_get_by_name->svc_export_lookup->sunrpc_cache_lookup->svc_export_init->path_get
the reference count can't be subtracted untill we stop nfsd or tcp idle timeout on server. the system call the cache_flush() to subtract the count.
then we can umount successfully.

do dou have some patches can umount immediately or some suggestions?


             reply	other threads:[~2017-05-16 12:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-16 12:57 Gu Zheng [this message]
2017-05-16 17:42 ` nfs+ext4,can not umount the ext4 mountpoint J. Bruce Fields
2017-05-17  7:18   ` Gu Zheng
2017-05-17 15:46     ` J. Bruce Fields
2017-05-18 10:59       ` Gu Zheng

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=591AF71F.1040703@huawei.com \
    --to=guzheng1@huawei.com \
    --cc=bfields@fieldses.org \
    --cc=houtao1@huawei.com \
    --cc=jlayton@poochiereds.net \
    --cc=linux-nfs@vger.kernel.org \
    --cc=miaoxie@huawei.com \
    --cc=zhaohongjiang@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox