本地 SSH 连接谷歌云服务器


首先,在浏览器登录 Google Cloud Platform 后台,使用浏览器 SSH 登录你需要配置本地连接的服务器。
切换至 root 用户:
sudo -i

编辑 ssh config 配置文件:

vim /etc/ssh/sshd_config

修改 PermitRootLogin 以及 PasswordAuthentication 为 yes,默认是 no:

#LoginGraceTime 2m
PermitRootLogin yes

...

#To disable tunne led clear text passwords, change to no here!
PasswordAuthentication yes

使 ssh 配置文件生效:

/etc/init.d/ssh restart

修改 root 密码:

passwd

然后输入要修改的密码,不会显示。再次输入。ok,使用外部 ip 连接即可