From: "bofh00" <jnielsen@aero-graphics.com>
Subject: Re: NIS/NFS automount question
Date: Thu, 31 Jul 2003 16:30:10 -0600 [thread overview]
Message-ID: <pan.2003.07.31.22.30.09.719470@aero-graphics.com> (raw)
In-Reply-To: bfh6c6$2aj$1@news.service.uci.edu
On Mon, 21 Jul 2003 10:05:14 +0000, Aaron J. Greenwood wrote:
> If I cd into /lin/data/aug2001 on a system running Linux or Irix pwd returns
> /lin/data/aug2001
>
> If I cd into /lin/data/aug2001 on a system running Tru64 pwd returns
> /tmp_mnt/lin/data/aug2001. This creates problems with scripts that use pwd.
>
> Is there a way to get pwd to drop the /tmp_mnt part of the path?
>
> I am running NIS, NFS and automount. For this file system the following is
> true:
>
> auto.master has the following line:
> /lin auto.lin -rw,intr
>
> auto.lin has the following line:
> data hostname.subdomain.uci.edu:/data
>
> On the Tru64 systems I am using automount
> On the Irix systems I am using autofs or automount
> On the Linux systems I am using autofs
>
> Any help would be appreciated.
Or just modify your scripts.
Use "uname" to check the os type and based on it or perhaps just look
for tmp_mnt in path. In either case you could something like the
following in the scripts.
FOO=`pwd 2>/dev/null | sed "s/.*\/tmp_mnt//g"`
That should strip the /tmp_mnt off and dump the rest in FOO. I think.
Didnt try it. Test it if you plan to use.
prev parent reply other threads:[~2003-07-31 22:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-07-21 17:05 NIS/NFS automount question Aaron J. Greenwood
2003-07-31 15:32 ` bofh00
2003-07-31 22:30 ` bofh00 [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox