From: Karel Zak <kzak@redhat.com>
To: Stanislav Brabec <sbrabec@suse.cz>
Cc: util-linux@vger.kernel.org
Subject: Re: umount of unreachable NFS without -f [maybe PATCH]
Date: Wed, 3 Sep 2014 09:49:15 +0200 [thread overview]
Message-ID: <20140903074915.GE21325@x2.net.home> (raw)
In-Reply-To: <1409684978.14709.15.camel@oct.suse.cz>
On Tue, Sep 02, 2014 at 09:09:38PM +0200, Stanislav Brabec wrote:
> I just analyzed causes of hang while calling umount without -f on an
> unreachable NFS.
>
> The first hang happens on in lookup_umount_fs():
>
> stat(tgt, &st) == 0 && S_ISDIR(st.st_mode)
>
> I don't exactly know, what its removal causes, but I tried it.
The stat() is there to detect situations when someone calls
umount /dev/sda1
then you don't want to call statfs() to get fs type, because the
device is not a mountpoint. Note that statfs() works with arbitrary
file, so we have to be careful...
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
prev parent reply other threads:[~2014-09-03 7:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-02 19:09 umount of unreachable NFS without -f [maybe PATCH] Stanislav Brabec
2014-09-03 7:45 ` Karel Zak
2014-09-03 13:30 ` Stanislav Brabec
2014-09-03 7:49 ` Karel Zak [this message]
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=20140903074915.GE21325@x2.net.home \
--to=kzak@redhat.com \
--cc=sbrabec@suse.cz \
--cc=util-linux@vger.kernel.org \
/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