I have a user set up with the following as his path:
/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games:
/opt/kde/bin:/usr/local/samba/bin:/opt/www/htdig/bin:
/usr/lib/java/bin:/usr/lib/java/jre/bin:/usr/lib/qt-3.2.1/bin:
/usr/share/texmf/bin:
Root has the following as his path:
/usr/local/sbin:/usr/sbin:/sbin:/usr/local/samba/sbin:
/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games:
/opt/kde/bin:/usr/local/samba/bin:/opt/www/htdig/bin:
/usr/lib/java/bin:/usr/lib/java/jre/bin:/usr/lib/qt-3.2.1/bin:
/usr/share/texmf/bin:
however when I log into kde as my user and using konsole do an su (or from
the console do an su) checking the path only gives me:
/usr/local/sbin:/usr/local/bin:/sbin:/usr/sbin:/bin:/usr/bin
why is this, is this by design or am I missing something?
The following is an exctract from my /etc/profile file, this is where if I
need to add a path i add it to the default system path
# set the default system $PATH
PATH="/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games:
/opt/kde/bin:/usr/local/samba/bin"
(the above line isn't wrapped in the file)
# For root users, ensure that /usr/local/sbin, /usr/sbin, and /sbin are in
# the $PATH. Some means of connection don't add these by default (sshd comes
# to mind).
if [ "`id -u`" = "0" ]; then
echo $PATH | grep /usr/local/sbin 1> /dev/null 2> /dev/null
if [ ! $? = 0 ]; then
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/samba/sbin:$PATH
fi
fi
Thanks for any help
Stuart