-2

In RedHat , I want to login with other user firstly in SSH, such as the user input when installing OS , then su - root , instead of being able to login with root directly in SSH How to set in command line and config files ? I have no UI .

closed as unclear what you're asking by jasonwryan, techraf, Wildcard, dr01, Ulrich Schwarz Nov 30 '16 at 7:30

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • I also want to be able to login with root by ssh , just should be su from other user in ssh , instead of login with root directly by ssh such as : login with user1 in ssh, then "su - root" , input the password of root , then switched to root in ssh – caiyufei Nov 30 '16 at 4:58
  • Possible duplicate of How do I disable remote root login via ssh? – Ulrich Schwarz Nov 30 '16 at 7:30
-1

Next time, try a magical thing called search engine before asking.

See here:

http://www.howtogeek.com/howto/linux/security-tip-disable-root-ssh-login-on-linux/

  • Thanks , I searched before asking , But ... had not found , Worked now – caiyufei Nov 30 '16 at 6:04
0

You need to disable root login you need to empty the /etc/securetty file so that the root user cant login via console for refrance here is the link disable console root login.

Not the answer you're looking for? Browse other questions tagged or ask your own question.