[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
a possible su bug...
From: |
Super-User |
Subject: |
a possible su bug... |
Date: |
Thu, 7 Jun 2001 17:36:45 -0700 (PDT) |
Reply-to: address@hidden
Hi there,
I'm on a solaris 2.7 system and have found (what I'd call a bug) with my head.
Here's
the scenario:
I do a su command to smuser and then type in which ps. With the (your?)
sh-utils su
command the results are /usr/ucb/ps BUT when I use suns su command, the which ps
command returns /usr/bin/ps. THIS IS DISASTEROUS for "us/me" because there are
scripts in ~smuser that just reference ps as ps, no path!!! Just ps. Of course,
you
know what's comming next, the /usr/ucb/ps command takes different parameters
than
/usr/bin/ps. Sigh...
Below is a log from the testing I've done.
If you require any more info or a place to test changes, please do NOT hesitate
to
contact me.
George R. Goffe
address@hidden
Thanks...
5.7 root->sjrd1# which su
/usr/lsd/SunOS.5.7/bin/su
5.7 root->sjrd1# su --help
Usage: su [OPTION]... [-] [USER [ARG]...]
Change the effective user id and group id to that of USER.
-, -l, --login make the shell a login shell
-c, --commmand=COMMAND pass a single COMMAND to the shell with -c
-f, --fast pass -f to the shell (for csh or tcsh)
-m, --preserve-environment do not reset environment variables
-p same as -m
-s, --shell=SHELL run SHELL if /etc/shells allows it
--help display this help and exit
--version output version information and exit
A mere - implies -l. If USER not given, assume root.
Report bugs to <address@hidden>.
5.7 root->sjrd1# su - smuser
Sun Microsystems Inc. SunOS 5.7 Generic October 1998
$ which ps
/usr/ucb/ps
$ ^D
5.7 root->sjrd1# psg wind
F S UID PID PPID CLS PRI ADDR SZ WCHAN STIME TTY
TIME CMD
8 S smuser 29666 1 TS 58 ? 477 ? 16:52:22 ?
0:00 ./windu_registryd43 -d /apps/smuser
5.7 root->sjrd1# /usr/bin/su - smuser
Sun Microsystems Inc. SunOS 5.7 Generic October 1998
$ which ps
/usr/bin/ps
$