1.修改配置檔案
vim /etc/ssh/sshd_config.

2.firewall開啟2222或者安全組開啟2222端口
firewall-cmd --zone=public --add-port=2222/tcp --permanent
3.重新開機sshd
systemctl restart sshd
4.重新遠端伺服器
1.修改配置檔案
vim /etc/ssh/sshd_config.
2.firewall開啟2222或者安全組開啟2222端口
firewall-cmd --zone=public --add-port=2222/tcp --permanent
3.重新開機sshd
systemctl restart sshd
4.重新遠端伺服器