fedora core 2
after SUing to root (or from root to any other user for that matter), the PATH and LIBPATH are all messed up (retain that of previous username).
there are some other strange side effects.
i RARELY log in as root, and if i do i demote to runlevel 3 first and turn off my network interface if i can.
so i usually just try to su to root. this works for most things, including yum update
but i always have to type /sbin/reboot, etc (since /sbin isn't in my path). I've tried adding /sbin to my path in root's .profile, but that should been in the default profile to begin with (basically the new user's profile isn't being read, plus some other strange stuff is going on)
this affects things like rebuilding the kernel.
since i don't like logging into X as root i can't do make gconfig to rebuild the kernel.
if i su to root i get:
*
* Unable to find the GTK+ installation. Please make sure that
* the GTK+ 2.0 development package is correctly installed...
* You need gtk+-2.0, glib-2.0 and libglade-2.0.
*
make[1]: *** [scripts/kconfig/.tmp_gtkcheck] Error 1
make: *** [gconfig] Error 2
prolly because the libpath and path are messed up.
[root@notaix linux]# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/erict/bin
other interesting vars (when SU'd to root):
HOME=/root
LOGNAME=erict
<-!!!!!!!!!
USER=erict
<-!!!!!!!!!
when i su to a user (from root), i get things like no permission to write to user's home. WTH?
any ideas on how to make this work properly?
this is a very new install and i haven't used a redhat distro in 5+ years.
TIA