In this example, browsability of the /net directory is disabled. You can use the same procedure for /home or any other autofs mount points.
Check the automount entry in /etc/nsswitch.conf.
For local file entries to have precedence, the entry in the name service switch file should list files before the name service. For example:
automount: files nisplus |
This entry shows the default configuration in a standard Solaris installation.
Check the position of the +auto_master entry in /etc/auto_master.
For additions to the local files to have precedence over the entries in the namespace, the +auto_master entry must be moved to follow /net:
# Master map for automounter # /net -hosts -nosuid /home auto_home /xfn -xfn +auto_master |
A standard configuration places the +auto_master entry at the top of the file. This placement prevents any local changes from being used.
Add the nobrowse option to the /net entry in the /etc/auto_master file.
/net -hosts -nosuid,nobrowse |
On all clients, run the automount command.
The new behavior becomes effective after running the automount command on the client systems or after a reboot.
# /usr/sbin/automount |