From: Neil Brown <neilb@suse.de>
To: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: linux-nfs@vger.kernel.org
Subject: Re: Strange lockup during unmount in 2.6.22 - maybe rpciod deadlock?
Date: Fri, 11 Jan 2008 12:07:54 +1100 [thread overview]
Message-ID: <18310.49514.808155.132856@notabene.brown> (raw)
In-Reply-To: message from Trond Myklebust on Thursday January 10
On Thursday January 10, trond.myklebust@fys.uio.no wrote:
>
> On Fri, 2008-01-11 at 08:51 +1100, Neil Brown wrote:
> >
> > Is this a credible scenario?
>
> Yes, but I have a scenario that I think trumps it:
>
> * the call that puts the open context is being made in
> nfs_commit_done (or possibly nfs_writeback_done), causing it to
> wait until the rpc_killall_tasks completes.
> * The problem is that rpc_killall_tasks won't complete until the
> rpc_task that is stuck in nfs_commit_done/nfs_writeback_done
> exits.
>
> Urgh...
Oh, yes, that would be ugly!
>
> I'm surprised that we can get into this state, though. How is
> sys_umount() able to exit with either readaheads or writebacks still
> pending? Is this perhaps occurring on a lazy umount?
It does sound like it has to be a lazy unmount, doesn't it? I don't
think autofs will do that. The computer in question was suspended
while on the slow slow network and when it resumed the problem hit.
So maybe there is a suspend-time script which did the lazy unmount.
I'll ask.
Meanwhile, I managed to reproduce it. It went something like:
Client:
mount -o soft,intr server:/home /mnt
{ echo open > /dev/tty ;sleep 10; echo writing > /dev/tty; \
exec cat /boot/bzImage-test; } > /mnt/testing
"open"
Server:
rpc.nfsd 0
Client:
"writing"
type control-C
umount -l /mnt
wait a little while, notice that one rpciod is in 'D' wait.
echo t > /proc/sysrq-trigger
See the same stack trace.
However I cannot do it again, so I cannot test a fix.
The only fix that occurs to me is to use schedule_work to shunt the
rpc_shutdown_client into a separate thread.
Thanks,
NeilBrown
next prev parent reply other threads:[~2008-01-11 1:08 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-10 21:51 Strange lockup during unmount in 2.6.22 - maybe rpciod deadlock? Neil Brown
[not found] ` <18310.37731.29874.582772-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2008-01-10 22:41 ` Trond Myklebust
2008-01-11 1:07 ` Neil Brown [this message]
[not found] ` <18310.49514.808155.132856-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2008-01-11 1:26 ` Trond Myklebust
[not found] ` <1200004896.13775.27.camel-rJ7iovZKK19ZJLDQqaL3InhyD016LWXt@public.gmane.org>
2008-01-14 19:01 ` Benjamin Coddington
2008-01-14 19:31 ` Trond Myklebust
[not found] ` <1200339108.7470.45.camel-rJ7iovZKK19ZJLDQqaL3InhyD016LWXt@public.gmane.org>
2008-01-14 20:28 ` Benjamin Coddington
2008-01-14 20:36 ` Trond Myklebust
[not found] ` <1200343018.7470.56.camel-rJ7iovZKK19ZJLDQqaL3InhyD016LWXt@public.gmane.org>
2008-01-14 21:09 ` J. Bruce Fields
2008-02-19 5:34 ` Neil Brown
[not found] ` <18362.27251.619125.502340-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2008-02-19 19:26 ` Trond Myklebust
[not found] ` <1203449166.8156.85.camel-rJ7iovZKK19ZJLDQqaL3InhyD016LWXt@public.gmane.org>
2008-02-19 23:18 ` Trond Myklebust
2008-02-21 5:16 ` Neil Brown
[not found] ` <18365.2329.495660.107605-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2008-02-21 13:34 ` Trond Myklebust
2008-02-21 4:58 ` Neil Brown
[not found] ` <18365.1274.387629.944796-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2008-02-21 12:16 ` Jeff Layton
2008-02-21 15:27 ` Trond Myklebust
2008-02-22 0:31 ` Neil Brown
[not found] ` <18366.6141.122127.181304-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2008-02-22 0:41 ` Trond Myklebust
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=18310.49514.808155.132856@notabene.brown \
--to=neilb@suse.de \
--cc=linux-nfs@vger.kernel.org \
--cc=trond.myklebust@fys.uio.no \
/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