emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Fixing dired hangs when NFS mount goes AWOL


From: Michael Olson
Subject: Re: Fixing dired hangs when NFS mount goes AWOL
Date: Wed, 5 Oct 2011 15:34:53 -0700

On Wed, Oct 5, 2011 at 3:14 PM, Glenn Morris <address@hidden> wrote:
>
>>>> Would you consider adding "-l" to the list of default arguments for
>>>> `directory-free-space-args'?  This will fix an issue where attempting
>>>> to open dired buffers with ls-lisp enabled hangs due to an AWOL NFS
>>>> mount.
>
> Could you explain what the issue actually is?
> Normally even trying to ls a directory containing eg a link to a missing
> NFS directory hangs.
>
> Are you saying that doing dired on a local directory that contains a
> link to a missing NFS mount works, but hangs in calling df to calculate
> the 'total used xxx available yyy' part?

The issue is that regardless of what directory you're trying to view
using dired, 'df' apparently still tries to stat *every* known
filesystem, including remote filesystems, before limiting its output
to just that of the filsystem for the given directory.  Changing the
df options by adding '-l' makes df only consider local filesystems, so
that it never tries to stat an NFS filesystem.

> What does ls-lisp have to do with it?

The call order is:
dired-insert-directory
insert-directory (version in ls-lisp.el is used)
get-free-disk-space
-> calls 'df'

> I can see how adding -l might help with a plain `df' call, but how can
> it help `df DIR' if DIR is local?

Apparently it's an issue in how df is implemented, in that it still
attempts to stat all existing mounts before narrowing the listing by
the directory param.  Possibly to resolve symlinks and get a
"truename"?

-- 
Michael Olson  |  http://mwolson.org/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]