How do I change my SSH port?

In this tutorial, we will demonstrate how to change your SSH port using the Serial Console in our portal.

  1. Visit Services

  2. Click on your VPS from the list of Services

  3. Click on HTML 5 Serial Console (screenshot)

  4. Click on Create Session (screenshot)

  5. Type the following, and press ENTER: sed -i 's/8145/22/' /etc/ssh/sshd_config (screenshot)
    This will change your SSH port from 8145 to 22

  6. Type the following, and press ENTER: service sshd restart (screenshot)
    This will restart the OpenSSH service


You should now be able to access your server on port 22

  • 1 Users Found This Useful
Was this answer helpful?

Related Articles

We currently offer the below Linux distributions: CentOS 6 64-bit CentOS 6 64-bit Minimal CentOS 7 64-bit CentOS 7 64-bit Minimal Debian 8 64-bit Debian 8 64-bit Minimal Debian 9 64-bit...

Read More ...

The username will always be root (by default), and the password is randomly generated. This password can be found in your welcome email.

Read More ...

We certainly do! Reverse DNS / rDNS / PTR records can be set via our control panel, using these steps: Select your VPS from the Services tab Click on Login to SolusVM VPS Control Panel » Click...

Read More ...

If you have SSH access and the server is still responding, you can log in as the root user and execute the reboot command. Otherwise, please follow the steps below to reboot your VPS. Select...

Read More ...

All of our VPS nodes have TUN/TAP support enabled. All you need to do is enable it on your VPS, which can be done using the below steps: Select your VPS from the Services tab (screenshot)...

Read More ...