远程连接阿里Sever
一、Linux开启ssh服务
- 安装ssh-server
sudo apt-get update
sudo apt-get install openssh-server
- 启动ssh服务
ps -e | grep ssh 检测shh是否启动
sudo /etc/init.d/ssh restart 启动ssh服务
service ssh status 查看ssh服务状态
1. service ssh start 启动ssh服务
2. service ssh stop 停止ssh服务
二、修改服务器内置文件
当使用远程连接工具连接的时候回出现:SSH error:a public key file has not been specified by this session
那么久需要更改config _config 文件文件
修改方法:
- 执行
vim /etc/ssh/sshd_config
- (1) 修改 PasswordAuthentication no
修改为: PasswordAuthentication yes - (2) 修改: #PubkeyAuthentication yes
修改为: PubkeyAuthentication no
- 重启服务器
service sshd restart
reboot
三、使用SecuCRT连接服务器
- 添加回话
- 自定义连接窗口名称
- 输入主机 IP 地址以及 用户名(U)
个人用户公网IP地址
- 输入用户密码
- 成功登录