How do I run a root command on Linux?
Answer:
If sudo is installed, you can use
sudo command
or you would need to change to root by using
su -
After login as root, you can execute the command.
Linux Ask! is a Q & A web site specific for Linux related questions. Questions are collected, answered and audited by experienced Linux users.
How do I run a root command on Linux?
Answer:
If sudo is installed, you can use
sudo command
or you would need to change to root by using
su -
After login as root, you can execute the command.
Why can't I telnet into my Linux box as root?
Answer:
By default, some distributions prohibit root from logging in remotely, unless you first log in as a regular user, and then "su" to root. This feature provides an extra layer of security in case the password of the root account is compromised.
Although it is not recommended, this restriction can be removed by deleting the file /etc/securetty. For more information, type "man securetty".