$SUPATH has no effect as root path

$SUPATH has no effect as root path

Post by robson s » Tue, 05 Nov 2002 08:07:11



Hi there,

Just installed Solaris 8 on my home LAN to get a feeling of the
all-powerful system admin. Now I'm stuck with a seemingly easy problem
but just can't figure it out...

I set PATH and SUPATH in /etc/profile. But after I login as root, I
can't execute some commands unless I specify the whole path. This is
how it goes:

(login as root)
# ifconfig -a
ifconfig: not found

# /usr/sbin/ifconfig -a
lo0: flags=1000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4> mtu 8232 index
1
        inet 127.0.0.1 netmask ff000000
xxx.....

# echo $PATH
/bin:/usr/bin:/usr/ccs/bin:/usr/local/bin:/etc:/opt/sfw/bin:

# echo $SUPATH
/bin:/sbin:/usr/bin:/usr/sbin:/usr/ccs/bin:/usr/local/bin:/usr/local/sbin:/etc:/opt/sfw/bin:

$PATH and $SUPATH are there but $SUPATH has no effect. Any idea on why
it doesn't work?

Thanks in advance!

Robson Sun

 
 
 

$SUPATH has no effect as root path

Post by Daniel Bir » Tue, 05 Nov 2002 08:43:39


try setting your $PATH to include /usr/sbin !!! :)

>Hi there,

>Just installed Solaris 8 on my home LAN to get a feeling of the
>all-powerful system admin. Now I'm stuck with a seemingly easy problem
>but just can't figure it out...

>I set PATH and SUPATH in /etc/profile. But after I login as root, I
>can't execute some commands unless I specify the whole path. This is
>how it goes:

>(login as root)
># ifconfig -a
>ifconfig: not found

># /usr/sbin/ifconfig -a
>lo0: flags=1000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4> mtu 8232 index
>1
>        inet 127.0.0.1 netmask ff000000
>xxx.....

># echo $PATH
>/bin:/usr/bin:/usr/ccs/bin:/usr/local/bin:/etc:/opt/sfw/bin:

># echo $SUPATH
>/bin:/sbin:/usr/bin:/usr/sbin:/usr/ccs/bin:/usr/local/bin:/usr/local/sbin:/etc:/opt/sfw/bin:

>$PATH and $SUPATH are there but $SUPATH has no effect. Any idea on why
>it doesn't work?

>Thanks in advance!

>Robson Sun


 
 
 

$SUPATH has no effect as root path

Post by robson s » Wed, 06 Nov 2002 03:40:26



> try setting your $PATH to include /usr/sbin !!! :)

Thanks for the reply, but I'm setting system wide environment
variables. I don't want /use/sbin to appear in each user account's
$PATH.  :-(
 
 
 

$SUPATH has no effect as root path

Post by Casper H.S. Di » Wed, 06 Nov 2002 05:20:59



>I set PATH and SUPATH in /etc/profile. But after I login as root, I
>can't execute some commands unless I specify the whole path. This is
>how it goes:

SUPATH is not used except initally when logging in from /etc/default/login

I.e., use:

        PATH=.....:$PATH

in /etc/.profile and root wil pick up $SUPATH as PATH and ordinary
users get the PATH from e/tc/default/login.

Casper
--
Expressed in this posting are my opinions.  They are in no way related
to opinions held by my employer, Sun Microsystems.
Statements on Sun products included here are not gospel and may
be fiction rather than truth.

 
 
 

1. crontab having effect on several machines

        Hi everybody,

        I would like to know if it is possible to set up a configuration for
several machines that can be affected by the contab file in one of them.
Does it rely on remote-logins and .rhost permissions on the target machines?
Is it possible to have a command be executed on a remote shell in a simple
format like 'host:command', and its result fed back to the user on the
machine the command was originally sent from?
        In all, what I would like to know is wether or not it is possible to
unify a set on unix machines as much as possible, beyond mounting their
respective filesystems, that is some kind of sharing of processor power and
resources without resorting to specialized microkernels (i.e. QNX).
        Any references will too be greatly appreciated.
                Thanks in advance,

                                Sincerely,

                                                Marc

2. Liquid

3. Ping from cron not having same effect as ping from console

4. Unknown ports listening for a connection.

5. Path as "su" doesn't equal path as root or as login user

6. Files Open

7. .bash_profile changes having no effect

8. What's signal 11 in solaris

9. playing mp3s and having gnome sound effects don't mix

10. default $PATH / $PATH for daemons running as root?

11. Q: Having '.' in your path

12. add in the PATH a path if not present in the PATH

13. Stupid $PATH question that I am ashamed to ask, but having no pride, I proceed