1.安装源
apt-get install openssh-server
2.然后确认ssh-server是否启动了
ps -e |grep ssh
3.启动ssh-server
service ssh start 或者 /etc/init.d/ssh start
4.停止ssh-server
service ssh stop或者 /etc/init.d/ssh stop
5.端口设置
/etc/ssh/sshd_config 文件
# What ports, IPs and protocols we listen forPort 22 修改端口(XXXX)
保存从新启动ssh-server