An su and prompt question

From: Kathy Ange (kathyange@yahoo.com)
Date: Mon Aug 12 2002 - 16:40:08 EDT


My question is how can I make my prompt change when I
su (It will change if I su - root, as it executes the
.profile) The problem is with Solaris 2.8 their isn't
a change so the user thought that su didn't work. For
that reason Solaris 2.6 is a bit better. Any suggests
would be appreciated.

I have two Operating Systems, one is 2.6 and the other
2.8
In both systems I use korn shell and in .profile I
have the following
     ENV=.kprofile
     export ENV

Then in the .kprofile I have
     PS1="`uname -n`: $LOGNAME: "$
     export PS1

With Solaris 2.6
foobar:kange: $id
uid=1004(kange) gid=10(staff)

foobar:kange: $pwd
/export/home/kange

foobar:kange: $su
Password:

# id
uid=0(root) gid=1(other)

# pwd
/export/home/kange
#

With Solaris 2.8

foobar2: kange: $id
uid=1001(kange) gid=10(staff)

foobar2: kange: $pwd
/export/home/kange

foobar2: kange: $su
Password:

foobar2: kange: $id
uid=0(root) gid=1(other)

=====
Kathy Ange
Virginia Department of Agriculture & Consumer Services
Information Systems
(804) 786-1340 Voice Mail
(804) 786-2110 FAX
HotJobs - Search Thousands of New Jobs
http://www.hotjobs.com
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers



This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 23:24:45 EDT