Oracle甲骨文Ubuntu无法远程SSH登录

手里还有两个永久免费的甲骨文云VPS,装的Ubuntu系统,开服的时候还教过大家Oracle Cloud SSH使用密码登录,前不久发现SSH突然登不上了,还以为甲骨文给回收了。后来一番探究,终于解决了。 得到的结论是,永久免费的东西,或者说甲骨文家的东西真的挺糟心的。 排查过程太曲折就不说了,直接说最后的解决方法: 用Cloud Shell或者Web上带的终端登录到服务器上,首先核对sshd和ssh服务有没有在运行。 sudo systemctl status ssh sudo systemctl status sshd 如果这俩没在运行,就先安装 sudo apt update sudo apt install openssh-server 设置开机启动 sudo systemctl start sshd sudo systemctl enable sshd 用你的编辑器编辑sshd配置文件 nano /etc/ssh/sshd_config 确保以下行没有被注释,并且端口设置正确: Port 22 PermitRootLogin yes PasswordAuthentication yes 保存配置文件后重启服务 ...

2025-10-21 · 1 min · Duke Yin