Linux serverNETWORK ADMINISTRATIONS

HOW TO SECURE OR CHANGE DEFAULT SSH PORT ON LINUX CENTOS 7

HOW TO SECURE OR CHANGE DEFAULT SSH PORT ON LINUX CENTOS 7

Instructions to secure default ssh port 22
Step1.
Edit SSHD (SSH server daemon) configuration file by using your favorite text editor:
nano /etc/ssh/sshd_config
*Add the following code to either the top or the bottom of the configuration file*
# SSH Port
Port 2020 # the port you want to change it
Step2.
Update the firewall. If you have disabled the firewall, then you can skip this step.
*Running below given commands for allowing new ssh port 2020*
firewall-cmd –add-port 2020/tcp –permanent
firewall-cmd –add-port 2020/tcp
Step3.
Restart the SSH server (SSHD)
service sshd restart

For Further Queries contact me

@Skype ID
mehria.noc1
Email ID xperttechsol@hotmail.com
Whatsapp
+923055013998

source

centos 7

Leave a Reply

Your email address will not be published. Required fields are marked *