Loading... ## 一、修改ssh配置文件并设置root密码 ### 1.首先使用Google Cloud SSH登录VPS  ### 2.切换到root账户 ``` sudo -i ```  ### 3.编辑sshd配置文件 ``` vim /etc/ssh/sshd_config ```  ### 4.修改以下内容即可 按键盘【i】进入编辑,按【Esc】退出编辑,再输入 **:wq** 保存并退出   ### 5.重启sshd服务 ``` service sshd restart ```  ### 6.为root账户设置密码 ``` passwd ```  输入密码 输入密码的时候不会显示出来,所以直接输入密码,然后回车,再然后重复输入密码回车  确认密码 再输入一次  设置成功  <hr class="content-copyright" style="margin-top:50px" /><blockquote class="content-copyright" style="font-style:normal"><p class="content-copyright">版权属于:大漠孤狼</p><p class="content-copyright">本文链接:<a class="content-copyright" href="https://www.dmgls.com/1339.html">https://www.dmgls.com/1339.html</a></p><p class="content-copyright">转载时须注明出处及本声明</p></blockquote> Last modification:November 2nd, 2022 at 07:05 am © 允许规范转载 Support 如果觉得我的文章对你有用,请随意赞赏 Appreciate the author