On Solaris, there is a combination gotcha with the automounter and mounts on the same host. It goes like this:
- your fileserver normally has /dev/whatever mounted on /export/foo.
- your generic automounter configuration mounts fileserver:/export/foo as /foo.
- you need to do some maintenance to the filesystem, so you unshare and unmount /export/foo.
- after you're done you try to remount it, but you get a message that the mount point is busy. The only mention of /export/foo that
mountshows is something that looks like:/foo on /export/foo ...
What has happened is that something on your fileserver tried to touch
/foo
during your maintenance, so the automounter went ahead and mounted it from where you told it to. Loopback mounts don't check NFS share permissions so the mount wasn't denied, and loopback mounts (like NFS mounts) just put directory A on directory B, so the automounter didn't stop because there was no filesystem there; there was an
/export/foo
directory and that was good enough.
The direct way out is
umount /foo
. Unfortunately this may not be good enough if something is actively banging on that name, because the automounter will just remount it again; you may need to find the something and shoot it.
(In our case it was mail delivery. Why we are doing mail delivery directly on the fileservers is a long story.)