反馈建议 标题:
邮箱:
内容:
  
[隐显目录]
登陆镜像终端后,进行如下操作

执行下边的命令生成密钥文件  一路回车即可
ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key

执行下边的命令生成 ed25519 密钥
ssh-keygen -t ed25519 -f /etc/ssh/ssh_host_ed25519_key

执行下边的命令生成 ecdsa密钥
ssh-keygen -t ecdsa -f /etc/ssh/ssh_host_ecdsa_key

执行下边的命令 拷贝密钥文件到home
cp -r /etc/ssh/ssh_host_* /home/

执行下边的命令修改ssh root的密码
/bin/bash -c "echo 'qqwwee123'|passwd --stdin root"

执行下边的命令让sshd运行起来
/usr/sbin/sshd -D &

执行下边的命令删除ssh key
rm -rf /home/ssh_host_*

到此为止,即可使用宝塔终端了!