Bryan Whitehead wrote: > Buchan Milne wrote: > >> Bryan Whitehead wrote: >> >> >>> Thanks for the kick in the pants. Looks like autofs can do what I need. >>> Looks like this "feature" slipped in during 9.0 (or 8.2) and I didn't >>> notice. >>> >>> Now if only autofs would support direct mounts we'd be another step >>> closer to Solaris... ;) >> >> >> >> Could you explain what it is/how it works? > > > auto_direct allows you to assign a directory a specific disk/nfsserver > when it is accessed. this means you can make any directory managed by > autofs without having autofs control the parent directory. > > most common use of direct mount is /var/mail. > > This config wants "mail" in /var/ to be mounted from a nfs server, but > you can't have "/var" managed by autofs. So autofs will watch the "mail" > directory directly. When a program enters/opens the directory autofs > will mount the directory from it's configured source. An auto.direct > entry would look like this: > /var/mail -actimeo=0 s383:/export/mail > > someone may say... "why don't you just keep in mounted??!?!". Because of > stale NFS handles when servers go down. Even when the server comes back > up the client may be hosed... if you have several hundred workstations > this can suck real fast. NFS mounts should only be mounted when "in > use". If no one is looking at /var/mail then /var/mail should not be > mounted via nfs. > > Currently on linux we would have to change /var/mail to be a symlink to > /net/s383/export/mail. However, this becomes a problem when applications > decide to save the "mail folder" as /net/s383/export/mail. If we move > our mail services to another server we'll have problems. But mail is > just a simple stupid example... > > /usr/local is software that is installed by the SA. Many shops share > this over nfs (very common at JPL) so each workstation can have new > software by installing it on the server... auto_direct would look like > this: > /usr/local -rw s383:/export/opt/local > > having /usr/local as a symlink to /net/export/opt/local can screw up > many things. For example, if a project compiles software on their > workstation configure/makefiles and binarys can end up with > /net/export/opt/local in them... resulting in huge problems when servers > are moved, or decommissioned. > >
BTW, it appears that autofs 4.1 has/will have direct mount support, including with maps in LDAP. ftp://ftp.kernel.org/pub/linux/daemons/autofs/v4/ Thomas, any chance of this in your kernel some time soon? ftp://ftp.kernel.org/pub/linux/daemons/autofs/v4/autofs4-2.4-module-20031013.tar.bz2 I will probably test it quite soon (some time next week I guess) myself either way, but this is definitely something that we will want to have in 10.0 ... Regards, Buchan -- |--------------Another happy Mandrake Club member--------------| Buchan Milne Mechanical Engineer, Network Manager Cellphone * Work +27 82 472 2231 * +27 21 8828820x202 Stellenbosch Automotive Engineering http://www.cae.co.za GPG Key http://ranger.dnsalias.com/bgmilne.asc 1024D/60D204A7 2919 E232 5610 A038 87B1 72D6 AC92 BA50 60D2 04A7