Hướng dẫn thay đổi port SSH CentOS 7
Hướng dẫn thay đổi port SSH CentOS 7
1. Bạn gõ lệnh này để cho phép port bạn cần thay đổi ssh
yum install policycoreutils-python
semanage port -a -t ssh_port_t -p tcp 3456
2. Bạn vào /etc/ssh/sshd_config
thay đổi port ssh như port tương ứng ở trên
3. Mở Firewall
firewall-cmd --add-port=3456/tcp --permanent firewall-cmd --reload
Reboot lại để kiểm tra
Chúc bạn thành công
|