top level mount point
Hey All,
I'm trying to get a "top-level" automount to work. eg
/home -rw,vers=3,fstype=nfs,intr,hard,tcp,rsize=32768,wsize=32768 srv1:/export/home/
I've tried a few things so far - putting that exactly as is into /etc/auto.master, created an auto.direct file and put /- auto.direct into auto.master neither any joy - also tried /home auto.home in auto.master and above but with * or / as the key as contents of auto.home none are working.
Firstly is this actually possible? Though I have no idea how Apple translate our maps into something automount uses they do get around this but /home is a symlink to somewhere like /private/var/automount/home. If its possible ...what have I missed to get this working?
TIA,
Shane.
Ian Kent
maintainerQuoted 4 lines · Shane
Hey All,
I'm trying to get a "top-level" automount to work. eg
Quoted 8 lines
/home -rw,vers=3,fstype=nfs,intr,hard,tcp,rsize=32768,wsize=32768 srv1:/export/home/
I've tried a few things so far - putting that exactly as is into
/etc/auto.master, created an auto.direct file and put /- auto.direct into auto.master neither any joy - also tried /home auto.home in auto.master and above but with * or / as the key as contents of auto.home none are working.
Not valid in auto.master.
An indirect map must have keys that are a directory component only, that is no "/"s.
So, in auto.master you can have:
/home auto.home
and auto.home as:
* srv1:/export/home/&
to mount /home/myname as srv1:/export/home/myname
You could leave out the "&" but I'm not sure that would be useful.
Quoted 6 lines
Firstly is this actually possible? Though I have no idea how Apple translate our maps into something automount uses they do get around this but /home is a symlink to somewhere like /private/var/automount/home. If its possible ...what have I missed to get this working?
No, not possible with version 4.
Single level indirect maps aren't possible by definition.
Single level direct maps are possible with version 5.
So, in auto.master you could have:
/- auto.home
and auto.home:
/home svr1:/export/home
/other/dir other:/export/other
and the like.
Ian
Quoted 51 lines · Ian Kent
Quoted 4 lines · Shane
Hey All,
I'm trying to get a "top-level" automount to work. eg
Quoted 9 lines
/home -rw,vers=3,fstype=nfs,intr,hard,tcp,rsize=32768,wsize=32768 srv1:/export/home/
I've tried a few things so far - putting that exactly as is into
/etc/auto.master, created an auto.direct file and put /- auto.direct into auto.master neither any joy - also tried /home auto.home in auto.master and above but with * or / as the key as contents of auto.home none are working.Not valid in auto.master.
An indirect map must have keys that are a directory component only, that is no "/"s.
So, in auto.master you can have:
/home auto.home
and auto.home as:
* srv1:/export/home/&
to mount
/home/mynameas srv1:/export/home/mynameYou could leave out the "&" but I'm not sure that would be useful.
Quoted 6 lines
Firstly is this actually possible? Though I have no idea how Apple translate our maps into something automount uses they do get around this but /home is a symlink to somewhere like /private/var/automount/home. If its possible ...what have I missed to get this working?
No, not possible with version 4.
Single level indirect maps aren't possible by definition.
Single level direct maps are possible with version 5.
So, in auto.master you could have:
/- auto.home
Quoted 10 lines
and auto.home:
/home svr1:/export/home
/other/dir other:/export/otherand the like.
Ian
Is there a good way to set up ldap entries so autofs 4 and 5 can each find and match its own version of automount maps?
Many times, one has to run different versions of Redhat distributions and not able to migrate to RHEL5 all together.
Simon
Ian Kent
maintainerQuoted 57 lines · Simon Gao
Quoted 56 lines · Ian Kent
Quoted 4 lines · Shane
Hey All,
I'm trying to get a "top-level" automount to work. eg
Quoted 9 lines
/home -rw,vers=3,fstype=nfs,intr,hard,tcp,rsize=32768,wsize=32768 srv1:/export/home/
I've tried a few things so far - putting that exactly as is into
/etc/auto.master, created an auto.direct file and put /- auto.direct into auto.master neither any joy - also tried /home auto.home in auto.master and above but with * or / as the key as contents of auto.home none are working.Not valid in auto.master.
An indirect map must have keys that are a directory component only, that is no "/"s.
So, in auto.master you can have:
/home auto.home
and auto.home as:
* srv1:/export/home/&
to mount
/home/mynameas srv1:/export/home/mynameYou could leave out the "&" but I'm not sure that would be useful.
Quoted 6 lines
Firstly is this actually possible? Though I have no idea how Apple translate our maps into something automount uses they do get around this but /home is a symlink to somewhere like /private/var/automount/home. If its possible ...what have I missed to get this working?
No, not possible with version 4.
Single level indirect maps aren't possible by definition.
Single level direct maps are possible with version 5.
So, in auto.master you could have:
/- auto.home
and auto.home:
/home svr1:/export/home
/other/dir other:/export/other
Quoted 8 lines
Quoted 5 lines
and the like.
Ian
Is there a good way to set up ldap entries so autofs 4 and 5 can each find and match its own version of automount maps?
The maps used with autofs v4 should all work with v5. If you find something that doesn't report it.
Quoted 3 lines
Many times, one has to run different versions of Redhat distributions and not able to migrate to RHEL5 all together.
Yes, and the other problem is mixed OS environments.
One goal of v5 is to be able to be able to "fit in" with other automount implementations, allowing a single set of map specifications. I think we're well along in this regard so if you find a case where this is broken report that too.
Generally v4 maps need to include ldap information so this can't be achieved with mixed v4 and v5 setups.
For example, in v4, you usually need something like:
automountInformation: ldap://<server name>/ou=<map name>,<basedn>
for all map entries. But in v5 it's generally best to use the map name only such as:
automountInformation: <map name>
and let the autofs work out the nsswitch source for the map.
Ian
..
..
..
[trimmed to provide clarity]
..
..
..
Quoted 8 lines
Quoted 3 lines
Is there a good way to set up ldap entries so autofs 4 and 5 can each
find and match its own version of automount maps?
The maps used with autofs v4 should all work with v5. If you find something that doesn't report it.
Quoted 1 line
Quoted 7 lines
Quoted 3 lines
Many times, one has to run different versions of Redhat distributions
and not able to migrate to RHEL5 all together.
Yes, and the other problem is mixed OS environments.
One goal of v5 is to be able to be able to "fit in" with other
automount implementations, allowing a single set of map specifications. I think we're well along in this regard so if you find a case where this is broken report that too.
Quoted 1 line
Generally v4 maps need to include ldap information so this can't be
achieved with mixed v4 and v5 setups.
Quoted 5 lines
For example, in v4, you usually need something like:
automountInformation: ldap://<server name>/ou=<map name>,<basedn>
for all map entries. But in v5 it's generally best to use the map name
only such as:
Quoted 5 lines
automountInformation: <map name>
and let the autofs work out the nsswitch source for the map.
Ian
As an add-on from practical experience. . .
I have found the "DAEMONOPTIONS='-Dvariable=value'" method in /etc/sysconfig/autofs (RedHat) invaluable to maintain a consolidated automap rather than one map per platform/version that is really serving the same purpose, particularly for network shared binaries, libraries and such. The map entries contain the variable embedded in the mount information as a subdirectory name. Here is an example:
/etc/sysconfig/autofs (RedHat):
DAEMONOPTIONS="-DOSV=rhel5_64"
/etc/default/autofs (Solaris 10):
AUTOMOUNTD_ENV=MOPT=-rw,rsize=8192,wsize=8192,proto=tcp,intr,noquota AUTOMOUNTD_ENV=OSV=Sun_sparc
auto.master:
/shared auto_shared
auto_shared:
bin $MOPT host1:/export/shared/$OSV/bin lib $MOPT host1:/export/shared/$OSV/lib etc $MOPT host1:/export/shared/etc
scripts $MOPT host1:/export/shared/scripts
On "host1" the file hierarchy would be:
/export/shared/
|- Sun_sparc/
|- bin/
|- lib/
|- rhel5_64/
|- bin/
|- lib/
|- etc/
|- scripts/On the UNIX systems, the mount options ($MOPT) are handled using the "-D" option where in Linux we handle it directly in the auto.master. On Linux, since the $MOPT is not provided for in the configuration, it resolves out to null and effectively is ignored. To the end user, the path is always the same no matter what platform/version they are logged into. This helps to simplify (in one respect) scripting in a multi-platform environment.
The assumption/limitation here is that the volume storing the shared files can be extended large enough to meet the requirements over all platforms/versions. For this application, it isn't a practical limitation anymore; just a factor in planning.
_______________________________________________
-----------------------------------------
Anadarko Confidentiality Notice:
This electronic transmission and any attached documents or other writings are intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. If you have received this communication in error, please immediately notify sender by return e-mail and destroy the communication. Any disclosure, copying, distribution or the taking of any action concerning the contents of this communication or any attachments by anyone other than the named recipient is strictly prohibited.
Quoted 57 lines · Simon Gao
Quoted 56 lines · Ian Kent
Quoted 4 lines · Shane
Hey All,
I'm trying to get a "top-level" automount to work. eg
Quoted 9 lines
/home -rw,vers=3,fstype=nfs,intr,hard,tcp,rsize=32768,wsize=32768 srv1:/export/home/
I've tried a few things so far - putting that exactly as is into
/etc/auto.master, created an auto.direct file and put /- auto.direct into auto.master neither any joy - also tried /home auto.home in auto.master and above but with * or / as the key as contents of auto.home none are working.Not valid in auto.master.
An indirect map must have keys that are a directory component only, that is no "/"s.
So, in auto.master you can have:
/home auto.home
and auto.home as:
* srv1:/export/home/&
to mount
/home/mynameas srv1:/export/home/mynameYou could leave out the "&" but I'm not sure that would be useful.
Quoted 6 lines
Firstly is this actually possible? Though I have no idea how Apple translate our maps into something automount uses they do get around this but /home is a symlink to somewhere like /private/var/automount/home. If its possible ...what have I missed to get this working?
No, not possible with version 4.
Single level indirect maps aren't possible by definition.
Single level direct maps are possible with version 5.
So, in auto.master you could have:
/- auto.home
and auto.home:
/home svr1:/export/home
/other/dir other:/export/other
Quoted 8 lines
Quoted 5 lines
and the like.
Ian
Is there a good way to set up ldap entries so autofs 4 and 5 can each find and match its own version of automount maps?
It depends on which version of autofs4 you are running. The latest versions are able to determine your default search base, but older versions cannot. So, if you want to be compatible across the board, the safest way to construct your ldap entries would be something like the following. Change out the schema for whichever schema you want to use.
dn: automountMapName=auto.master,dc=autofs,dc=test
objectClass: top
objectClass: automountMap
automountMapName: auto.master
dn: automountKey=/home,automountMapName=auto.master,dc=autofs,dc=test
objectClass: automount
automountKey: /home
automountInformation: ldap: automountmapname=auto.home,dc=autofs,dc=test
dn: automountMapName=auto.home,dc=autofs,dc=test
objectClass: top
objectClass: automountMap
automountMapName: auto.home
dn: automountKey=/,automountMapName=auto.test,dc=autofs,dc=test
objectClass: automount
automountKey: /
automountInformation: srv1:/export/&
Cheers,
Jeff