34.2 Configuring Automounter

   

Automounter is started by the nfs.client script in the /sbin/init.d directory during the system boot process at run level 2. It reads its configuration information from the /etc/rc.config.d/nfsconf file. The following variables are used for automount configuration.

 AUTOMOUNT=1 AUTO_MASTER="/etc/auto_master" AUTO_OPTIONS="-f $AUTO_MASTER" 

The AUTOMOUNT value determines if the automount daemon will be started at boot time. A value of 1 enables startup and a value of disables it. The AUTO_MASTER variable shows the file name of the master automount map. The default name is /etc/auto_master , and you are free to change this to any other file. The AUTO_OPTIONS variable shows the set of options that are passed to the automount daemon at startup time. The -f option passes the name of the master map file to the automount daemon. Other useful options that can be used with automount are listed in Table 34-1. Please note that the automount daemon can also be started at any time using the same options on the command line.

Table 34-1. Options Used with the automount Daemon
Option Description
-T This option is used for tracing and debugging purposes. The activity is logged in the /var/adm/automount.log file.
-v Verbose. When this option is used with automount , it logs events and status messages to syslog . The messages can be found in the /var/adm/syslog.log file.
-f Used to specify the master map file name.
-M Used to specify the mount directory. This directory is used in place of the /tmp_mnt directory.
-tl Used to specify time in seconds for which a directory remains mounted without any activity. The default is 300 seconds. If no file is accessed in the directory during this time, the directory is unmounted.
-tm This specifies time in seconds used as the interval between mount attempts. The default is 30 seconds. If a mount attempt fails, Automounter retries the mount attempt after this time interval.
-tw This is used to specify time in seconds between retries to unmount a file system. The default value is 60 seconds.

The procedure of configuring Automounter may be completed in the following steps.

  1. Make sure that the required file systems are exported by the NFS server. You can use the showmount command with the -e option for this purpose.

  2. Edit the /etc/rc.config.d/nfsconf file to set proper configuration parameter values for Automounter.

  3. Create the master map file.

  4. Create direct and indirect map files as listed in the master map file.

  5. If the automount daemon and NFS clients are not started yet, start these using the nfs.client script as follows .

     /sbin/init.d/nfs.client start 

    If automount is already running, kill it using SIGTERM (Signal 15) and then restart it. Signals are discussed in Chapter 20. You can also reboot the system to start Automounter.

  6. Access a directory in the map files to verify that it is mounted.


   
Top


HP Certified
HP Certified: HP-UX System Administration
ISBN: 0130183741
EAN: 2147483647
Year: 2000
Pages: 390
Authors: Rafeeq Rehman

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net