终端运行
cd /etc/ssh/
编辑:
vim sshd_config
发现如下字符:
# If you want to change the port on a SELinux system, you have to tell
# SELinux about this change.
# semanage port -a -t ssh_port_t -p tcp #PORTNUMBER
#change port yzy 20187111556 /#port:22
Port 15678
#AddressFamily any
#ListenAddress 0.0.0.0
#ListenAddress ::
尝试连接端口15678,成功了。