Comment 7 for bug 988394

agenkin (agenkin-p) wrote :

Steve, I think that you are both right and wrong. You are right that autofs.conf does not work properly and that the autofs-related stuff should be stopped before umountfs script runs. However, there are two other things:

1. The entries in /proc/mounts with 'autofs' FSTYPE *are not file systems that need unmounting*, hence it is both safe and valid to ignore them in the umountfs script. The real file systems that have been mounted by the automounter would show up as separate entries in /proc/mounts with the proper FSTYPE ('ext4', 'nfs' or whatever).

2. The fstab-decode command should not hang on any input. It should be more robust and handle the inconsistencies like this more gracefully. Especially it should not hang when given a mount point at which no file system is mounted, which is the case here.

In other words, I think that my patch to the umountfs script is correct in as much as it accounts for the imperfect world in which the automounter was not shut down properly and fstab-decode can be hung.

The patch is also completely safe because ignoring the 'autofs' entries from /proc/mounts is completely harmless since they are not mounted file systems.