LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Su Command (https://www.linuxquestions.org/questions/linux-newbie-8/su-command-161258/)

aaronruss 03-23-2004 03:03 AM

Su Command
 
When I am logged in as a user and use the SU command in the console. it will not allow me to do every thing I can as root.

I thought su maid a user root.

Example:

I use su and issue the command "service network restart"

I get an error but if I login as root and issue the same command it restarts my network service.

Why can't I restart the network service using SU command?

OS = Fedora core1
Desktop = gnome

Tinkster 03-23-2004 03:09 AM

Because you use su, and not su -

That way you preserve your own environment,
and root's $PATH that contains various /sbin
directories doesn't get used....

man su
for details...


Cheers,
Tink

bigjohn 03-23-2004 09:38 AM

And if you find the manpages a bit to "techno speak" there's a link on how to interpret them in my sig.

regards

John

aaronruss 03-23-2004 04:44 PM

Thanks

I checked the man pages and info pages and found the switches for the SU command.

I used "SU -l" and the root password it allowed me to restart the services.

Tinkster 03-23-2004 05:56 PM

Of course it does, didn't you trust me? :)


Cheers,
Tink


All times are GMT -5. The time now is 10:41 AM.