VPS Murah Server IIX - USA - Singapore

Cara mengganti port SSH linux centOS

Cara mengganti port SSH sebagai berikut :

1. Login ke SSH dengan menggunakan putty
2. Ketikkan perintah : nano /etc/ssh/sshd_config
 #       $OpenBSD: sshd_config,v 1.73 2005/12/06 22:38:28 reyk Exp $
# This is the sshd server system-wide configuration file.  See
# sshd_config(5) for more information.
# This sshd was compiled with PATH=/usr/local/bin:/bin:/usr/bin
# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented.  Uncommented options change a
# default value.
#Port 22
#Protocol 2,1
Protocol 2
#AddressFamily any
#ListenAddress 0.0.0.0
#ListenAddress ::
3. Dari contoh di atas, Anda cukup perhatikan yang saya beri warna merah. Anda cukup ganti “#Port 22” dengan “Port 505” jika Anda ingin mengubahnya menjadi port 505. Seperti contoh di bawah ini :
#       $OpenBSD: sshd_config,v 1.73 2005/12/06 22:38:28 reyk Exp $
# This is the sshd server system-wide configuration file.  See
# sshd_config(5) for more information.
# This sshd was compiled with PATH=/usr/local/bin:/bin:/usr/bin
# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented.  Uncommented options change a
# default value.
Port 505
#Protocol 2,1
Protocol 2
#AddressFamily any
#ListenAddress 0.0.0.0
#ListenAddress ::
Kemudian tekan tombol CTRL + X untuk menyimpan.
4. Lalu restart SSH dengan perintah : /etc/init.d/sshd restart
5. Tutup Putty Anda, lalu cobalah login lagi ke SSH dengan port 505.
Demikian selesai sudah kita mengganti port default SSH menjadi custom port SSH yang kita inginkan pada VPS atau Dedicated Server sendiri. Selamat Mencoba pada akun VPS anda!


0 comments:

Post a Comment