GIT – Enable or Direct Login : many data centers disable direct login to servers for reason. You need to login first as a normal user than su to login as ( on and )

But i like direct login as root. So i disabled this extra security on my servers. If some one can get my root , they can also get my normal users . So what i do is use complicated root and keep it secure.

To enable or disable root login, you need to set this in /etc/ssh/sshd_config file.

# cd /etc/ssh
# vi sshd_config

To disable direct root SSH login, you need to add following to /etc/ssh/sshd_config

PermitRootLogin no

To enable direct root SSH login, you need to add following to /etc/ssh/sshd_config

PermitRootLogin yes

After you do the changes, save and exit. Then restart sshd.

On FreeBSD

# /etc/rc.d/sshd restart

On Linux

# /etc/init.d/sshd restart

Now you will be able to login to SSH directly as root. I use RSA key for authentication, so just double click on the server entry will get me login, no passwords to remember. Only thing is i have to keep my Private Key secure.

Print Friendly

Comments

comments

Bài viết liên quan