Select Page

It is probably best to change the default SSH port to add some protection to your server. You need to change the SSH server’s configuration file by running the following command.

nano /etc/ssh/sshd_config

It opens up the config file in NANO editor.

Look for the line that starts with Port 22.Comment out this line like this:

#Port 22

and add a new line with new port number of your own liking. You can choose a number between 1025 and 65536.

Port 9696

Press Ctrl + x to save the file.

Restart the SSH server by executing this command

Service ssh restart