Description of problem:
df -l hangs on nfs share when autofs is involved
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. define any export on rhel7 server
# cat /etc/exports
2. Configure /net automount entry
# cat /etc/auto.master
3. check that you can browse nfs share
# ls -l /net/rhel7-1/var/export/
-rw-r--r--. 1 root root 0 Feb 16 09:03 1
4. stop nfs on server
# systemctl stop nfs-server
5. run df -l <- local filesystems
df shows local file systems
if nfs share mounted directly then df -l filters it out and does not hang.
It hangs on a stat() call in filter_mount_list(). The autofs file system is not recognized as a remote file system (for which the stat() call is avoided) because there is no ':' in the mounted file (as in the case of NFS mounts). This behavior does not anyhow differ from the latest upstream version of df.
Fix proposed to gnulib upstream:
Note that this bz will also result in all exported filesystems from a particular nfs server becoming mounted, and can cause problems even if the nfs server is still running (such as when the nfs server is remote and has a large number of exports).
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.