Try su -
Ref: info su
`-'
`-l'
`--login'
Make the shell a login shell. This means the following. Unset
all environment variables except `TERM', `HOME', and `SHELL' (which
are set as described above), and `USER' and `LOGNAME' (which are
set, even for the super-user, as described above), and set `PATH'
to a compiled-in default value. Change to USER's home directory.
Prepend `-' to the shell's name, intended to make it read its
login startup file(s).
Andy Weller wrote:
> Dear all,
>
> I recently re-installed LM 8.2 onto my PC after the hard-drive went down
> (damn Viglen PC's!). I'm not too sure what I have done somewhere along
> the line but if I 'su' to root in my bash shell I have lost all but
> basic commands (e.g. modprobe, lsmod, urpm*, etc.). What is really
> puzzling is if I log into root X then open a shell these commands are
> there...?!?!
>
> What do I have to change in order to get all commands found/working
> after I 'su' from my user bash shell?!?
>
> Thanks,
>
> Andy
>
>
>
>
> ------------------------------------------------------------------------
>
> Want to buy your Pack or Services from MandrakeSoft?
> Go to http://www.mandrakestore.com
Want to buy your Pack or Services from MandrakeSoft?
Go to http://www.mandrakestore.com