jimtse
sudo passwd root
sudo passwd --unlock root
sudo sed -i "s/^#PermitRootLogin.*/PermitRootLogin yes/g" /etc/ssh/sshd_config
sudo systemctl restart ssh
sudo cp ~/.bashrc /root/.bashrc
Jim Tse
https://jimtse.eu.org:88/Linux/linux-root-and-ssh.html(转载时请注明本文出处及文章链接)
《署名-非商业性使用-相同方式共享 4.0 国际 (CC BY-NC-SA 4.0)》许可协议授权