close
close
ABOUT US AFFIALITES CONTACT US LOGIN CLIENT AREA
menu
+3197010282575 We also take care of providing excellent support 24/7 at no additional cost.

BLOGS

Change the default SSH listening port

01.16.2023

Change the default SSH listening port
One of the first things to do on your server is to configure the SSH port.
By default SSH service is listening on 22 port, but it's advisable to change it and not to leave it set to default values.
Because many new bots attack the default SSH port and make a brute-force to try to hack our login details.
To avoid these requests what you need is only follow this guide.

Run this command to open the service file configuration with the editor nano:

nano /etc/ssh/sshd_config

At the beginning of the file you will find something like that:

#Port 22

Uncomment this line removing the "#" character and change the number port from 22 to whatever you want but pay attention to put a port that is not already used.

After that save and exit from the editor, to apply these setting you need to restart ssh service by run this command: 



service ssh restart or service sshd restart