add PATH as root

Sorry this maybe a dumb one, but I am root and want to add something to my PATH.

Is the right place to do it here:
/usr/dt/config/dtspcdenv ?

If so, after I add it, how do I source it? Neither
"source <file>" nor ". <file>" work.

How does the above file work... is there another place to put it?

do you mean this:

PATH=$PATH:/my/path/here export PATH

No, I mean what file do you put that in (as root)?

And how do you invoke it after (without re-logging in).

use the ".profile" in roots home directory. or /etc/profile for a system wide setting...

1 Like

or set the SUPATH variable in /etc/default/login & /etc/default/su

1 Like

to invoke it again if you place it in your .bashrc or .kshrc depending on what shell you use you can just open a new shell