修改谷歌云google cloud engine VM root账户的密码和允许远程ssh登录

 

Figured it out. The VM's in cloud engine don't come with a root password setup by default so you'll first need to change the password using

sudo passwd

If you do everything correctly, it should do something like this:

user@server[~]# sudo passwd
Changing password for user root.
New password: 
Retype new password: 
passwd: all authentication tokens updated successfully.



cat /etc/ssh/sshd_config 
PermitRootLogin yes
PasswordAuthentication yes


systemctl restart sshd

 
 
原文地址:https://www.cnblogs.com/weifeng1463/p/10314269.html