Is this correct for automounter entry pointing to local file system?

Is this correct for automounter entry pointing to local file system?

Post by Michael Huck » Wed, 11 Feb 1998 04:00:00



I want to remap some directories from /usr to a different location on the
same machine.  First I add a "/-" entry to the auto_master file:

    # Master map for automounter
    #
    +auto_master
    /net            -hosts          -nosuid,nobrowse
    /home           auto_home       -nobrowse
    /xfn            -xfn
    /-              auto_direct

Then in /etc/auto_direct, I put the following as a test:

    /usr/demo       /x/opt/usr/demo

But this fails.  Upon trying to cd to /usr/demo, the following is printed in
/var/adm/messages:

  automountd: mapline_to_mapent: bad location= map=auto_direct key=/usr/demo
  automountd: parse_entry: mapentry parse error: map=auto_direct key=/usr/demo

Now if I change auto_direct to be

    /usr/demo       host:/x/opt/usr/demo

were "host" is the name of the current host, it works.  That's fine, but I
could have sworn that I read in the NFS manual for Solaris 2.6 that one can
omit the "host:" specifier.  Is this not the case, and is the above the way
that one is supposed to create a direct map entry that points from one
location on the local file space to another?

--

 PhD to be, computational models of human visual processing (AI Lab)     of
   UNIX systems administrator & programmer/analyst (EECS DCO)         Michigan

 
 
 

Is this correct for automounter entry pointing to local file system?

Post by Logan Sh » Thu, 12 Feb 1998 04:00:00




Quote:>I want to remap some directories from /usr to a different location on the
>same machine.  First I add a "/-" entry to the auto_master file:

  :
  :
Quote:>Then in /etc/auto_direct, I put the following as a test:

>    /usr/demo       /x/opt/usr/demo

  :
  :

Quote:>Now if I change auto_direct to be

>    /usr/demo       host:/x/opt/usr/demo

>were "host" is the name of the current host, it works.  That's fine, but I
>could have sworn that I read in the NFS manual for Solaris 2.6 that one can
>omit the "host:" specifier.  Is this not the case, and is the above the way
>that one is supposed to create a direct map entry that points from one
>location on the local file space to another?

I have also read the same thing an I have also not been able to get
it to actually work.  You can, however, do this:

        /usr/demo       localhost:/x/opt/usr/demo

And that will solve the problem.  Luckly, the automounter factors out
the NFS when it realizes the filesystem is local, so there is not a
significant performance penalty.

Another way to handle this, by the way, is to simply put loopback
mounts in your /etc/vfstab.  If you are doing this for just one system,
or if your mapping of directories will not be the same on all systems,
I actually like this idea better.  Do a "man lofs" if you want, but you
can edit /etc/vfstab as long as you remember that the "device" is the
pathname of the existing directory, the filesystem type is "lofs",
there is no device to fsck, and your new entry needs to go at the end
of /etc/vfstab, so it mounts after the other filesystems.

Finally, you might find that /usr/demo corresponds basically one-to-one
to a set of packages.  In fact, I think it does correspond to SUNWosdem
and SUNWjvdem.

   * "pkgrm SUNWosdem SUNWjvdem"
   * make sure /usr/demo is empty; it should be.
   * use "pkgadd" with the right option ("-R"?) to install the
        packages but relocated to another directory.

I have done something like this with CDE, since there wasn't sufficient
space in /usr/dt, and it worked like a charm.  I do forget, however,
whether it was "pkgadd -R" or something else that I used to accomplish
it.  (Might have been that "install_cde" script on the old Solaris 2.5
CDE CD.)

  - Logan

 
 
 

1. NFS clients don't follow mount point on server to correct file system device

My Solaris Ultra10 server is sharing direcories out to be remote mounted by
Windows 2000 and FreeBSD clients. All is working fine as long as the file
system on the server doesn't have nested directories to other devices, that
is:
/export/home -> c0d0t0s7
/export/home2 -> c0d0t1s7
I share /export, the NFS clients see /export and the directories home and
home2, but they do not follow the mount points to the appropiate file
systems - they go underneath!
Can I mount the devices on the server any other way to prevent access to the
filesystem underneath the mount points? I can't access the file system under
the devices on the server (unless I unmount the devices) Is this something
to do with the overlay switch? I don't want to unmount the current devices,
so can I set up another mount point for each file system with different
settings (such as 'mount -F ufs -o largefile -O /dev/dsk/c0t0d0s7 /test'
this says that /dev/dsk/c0t0d0s7 is already mounted or /test is in use).
Windows 2000 lets me mount drives to multiple drive letters or folders etc.,
I can't believe Solaris can't.
Thanks,
Mark.

2. can't get x2 connect with Linux

3. How can I get the system call entry point in the kernel mode?

4. e2fsck: Bad Superblock?

5. System call entry point ?

6. NCSA Telnet

7. tunnel point to point vs physical point to point

8. Video encoders

9. How to find system file pointing to mirror files

10. Changing permissions on file underlying the mount point without unmounting file system

11. what do entry points of object files mean?

12. Enhanced Filing system - file system like DEC Advanced File system for Linux

13. Correct amd automounter "direct map" setup under RH?