Mengganti Port SSH CentOS 7

yum -y install nano
nano /etc/ssh/sshd_config

Hapus tanda commnet # di line portnya ssh lalu ganti port 22 menjadi port yang kalian inginkan (contoh port 2000), lalu tekan pada keyboard CTRL+X, lalu Y, kemudian ENTER untuk kembali;

yum -y install policycoreutils-python
semanage port -a -t ssh_port_t -p tcp 2000
firewall-cmd --permanent --zone=public --add-port=2000/tcp
service sshd restart
ss -tnlp | grep ssh
reboot


Selamat mencoba.

Sumber: https://www.jagoanserver.com
Sebagai Dokumentasi.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s