Operating System - HP-UX
1753404 Members
7400 Online
108793 Solutions
New Discussion юеВ

Re: How to find the correct "autofs" configuration file.

 
SOLVED
Go to solution
senthil_kumar_1
Super Advisor

How to find the correct "autofs" configuration file.

Hi All,

I am using HPUX 11.11, 11.00 and 10.20.

I am seeing lot files for autofs configurations.

1)Server A:

1.1) autofs configuration files:

root@lgprime:/etc/rc.config.d > ll /etc/auto*
-rw-rw-rw- 1 root sys 19 Dec 18 2001 /etc/auto.direct
-rw-r--r-- 1 root sys 994 Dec 17 2001 /etc/auto.direct.022501
-rw-r--r-- 1 root sys 1068 Dec 17 2001 /etc/auto.direct.121701
-rw-r--r-- 1 root sys 1068 Dec 17 2001 /etc/auto.direct.121801
-r--r--r-- 1 root sys 4096 Dec 18 2001 /etc/auto.direct.dir
-r--r--r-- 1 root sys 2048 Dec 18 2001 /etc/auto.direct.pag
-rw-r--r-- 1 root sys 1416 Oct 10 2002 /etc/auto_direct
-rw-rw-rw- 1 root sys 2152 Dec 18 2001 /etc/auto_direct_new
-rw-rw-rw- 1 root sys 2356 Aug 15 2008 /etc/auto_lgprime
-rw-rw-rw- 1 root sys 2444 Jan 1 2003 /etc/auto_lgprime.010103
-rw-rw-rw- 1 root sys 1923 Jul 1 2002 /etc/auto_lgprime.063002
-rw-rw-rw- 1 root sys 2596 Dec 16 2002 /etc/auto_lgprime.121602
-rw-rw-rw- 1 root sys 2356 Jan 7 2009 /etc/auto_lgprime.dea
-rw-rw-rw- 1 root sys 2461 Oct 7 2002 /etc/auto_lgprime.wayne
-rw-rw-rw- 1 root sys 2467 Oct 7 2002 /etc/auto_lgprime.wayne1
-rw-rw-rw- 1 root sys 1938 Dec 18 2001 /etc/auto_lgprime_new
-rw-r--r-- 1 root root 43 Dec 17 2001 /etc/auto_master
-rw-r--r-- 1 root sys 15 Dec 17 2001 /etc/auto_master.121701
-rw-r--r-- 1 root root 1474 Mar 11 07:15 /etc/auto_parms.log
-rw-r--r-- 1 root sys 219 Mar 11 06:54 /etc/auto_parms.log.old
-rw-rw-rw- 1 root sys 1973 Oct 10 2002 /etc/auto_wayne


1.2)nfsconf file:

# more /etc/rc.config.d/nfsconf

AUTOMOUNT=1
AUTOMOUNT_OPTIONS="-v -f /etc/auto_master -t 86700"
AUTOMOUNTD_OPTIONS="-T -v"


2)Server B)

2.1) autofs configuration files:

root@lgapps:/root > ll /etc/auto*
-rw-rw-rw- 1 root sys 20 May 14 2002 /etc/auto.direct
-rw-rw-rw- 1 root sys 1149 Oct 12 2006 /etc/auto_ad002223
-rw-rw-rw- 1 root sys 2588 Apr 21 2006 /etc/auto_direct
-rw-r--r-- 1 root root 43 May 14 2002 /etc/auto_master
-rw-r--r-- 1 root root 119 Nov 12 2008 /etc/auto_parms.log
-rw-r--r-- 1 root sys 219 Nov 12 2008 /etc/auto_parms.log.old


2.2)nfsconf file:

# more /etc/rc.config.d/nfsconf

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


3)serverC

3.1)autofs configuration files:

root@ad121991.emdna.emdiesels.com:/etc/rc.config.d > ll /etc/auto*
-rw-rw-rw- 1 root sys 12 Mar 7 2005 /etc/auto.direct
-rw-rw-rw- 1 root sys 823 Sep 24 2007 /etc/auto_direct
-rw-rw-rw- 1 root sys 751 Sep 24 2007 /etc/auto_direct.orig
-rw-r--r-- 1 root root 69 Mar 7 2005 /etc/auto_master
-rw-r--r-- 1 root root 44 Jan 6 2009 /etc/auto_parms.log
-rw-r--r-- 1 root sys 219 Jan 6 2009 /etc/auto_parms.log.old


3.2)nfsconf file:

# more /etc/rc.config.d/nfsconf

AUTOFS=1
AUTOMOUNT_OPTIONS="-f $AUTO_MASTER"
AUTOMOUNTD_OPTIONS=""


Pls explain me that what is the configuration file for entering NFS shares details for each servers and how to find that.
4 REPLIES 4
Pete Randall
Outstanding Contributor
Solution

Re: How to find the correct "autofs" configuration file.

The config file is whatever file is identified in /etc/rc.config.d/nfsconf. In your case, it points to /etc/auto_master except for serverC, which does not tell us what $AUTO_MASTER is set to.


Pete

Pete
Sharma Sanjeev
Respected Contributor

Re: How to find the correct "autofs" configuration file.

Hi Senthil

For NFS you can mantain /etc/exports
& can run exportsfs -a

Automount
The central configuration file is
/etc/auto_master

Regards
Sanjeev
Everything is Possible as " IMPOSSIBLE" word itself says I M POSSIBLE
Mel Burslan
Honored Contributor

Re: How to find the correct "autofs" configuration file.

As Pete said, you need to know what the value assigned to $AUTO_MASTER variable is when nfsconf is sourced to have your exact picture. Having said that, I did not see any hpux autofs implementation myself where this value is played with and not the default value.

By default, your /etc/auto_master will look something like this:

# cat /etc/auto_master
/- /etc/auto.direct -nosuid,soft

here the important value is auto.direct. And I have seen this being a different value depending on implementer's style and how they used it. But forthe sake of simplicity, let's assume you have /etc/auto.direct as this value on your system(s). When you look at the contents of this file you will see things like this:

/usr/sap/trans -proto=tcp,vers=3 npf01.domain.com:/R3P_trans
/xfer -proto=tcp,vers=3 npf01.domain.com:/TSTsapxfer
/hotbackup -proto=tcp,vers=3 npf02.domain.com:/orahb
/DIRECTLINK -proto=tcp,vers=3 npf03.domain.com:/directlink_dev

You pretty much look at one of the lines in your auto.direct file and replicate it, then modify it to reflect the server and the filesystem, depending on your needs.

Don't forget, the autofs is still governed by the same access rules as NFS does, i.e., make sure your guest system has nfs.client running and the master server is allowing your guest system to access this share.

Hope this helps


________________________________
UNIX because I majored in cryptology...
TTr
Honored Contributor

Re: How to find the correct "autofs" configuration file.

In serverA, the "-f" option for the automounter is using explicitly the file name "/etc/auto_master".
In serverB, the "-f" option is using the "$AUTO_MASTER" variable which is initialized to the "/etc/auto_master" in the previous line. So serverB is using the same file name as serverA.
In serverC, the "-f" option is also using the "$AUTO_MASTER" variable but this variable is NOT initialized. So unless the "AUTO_MASTER" variable is initialized somewhere else, the automounter probably does not start up. Check the /etc/rc.log file on serverC to see if there is an error.

Also serverA and serverB are using the AUTOMOUNT=1 variable, where serverC is using the AUTOFS=1 variable to enable the automounter. It is the same functionality just different name. The AUTOMOUNT was used in HP-UX 10.20 and 11.00, 11.11, and the AUTOFS is used in 11.23. Same idea different name.

All the other files in /etc/auto* appear to be backup copies of /etc/auto_master that previous unix admins made before making any changes to the auto_master file.