How to use alternate SSH port for DR in place default port 22

Document ID : KB000016544
Last Modified Date : 14/02/2018
Show Technical Document Details

Client may want to use different port for SSH for DR machines.


How to use non standard SSH port to configure passwordless SSH for DR machines?

CAPC 3.x.OS Linux

Follow the below instructions:

  1. Connect to your server via SSH.
  2. Switch to the root user.
  3. Run the following command:
    vi /etc/ssh/sshd_config
  4. Locate the following line:
    # Port 22
  5. Remove # and change 22 to your desired port number.
  6. Restart the sshd service by running the following command:
    service sshd restart
  7. On each DR server:
    1. Create ~root/.ssh/config on each box and add:


      Host DR1HOSTNAME

          Port 16107 


      Host DR2HOSTNAME

         Port 16107 


      Host DR3HOSTNAME

         Port 16107 

    2. Repeat above step for ~dradmin/.ssh/config for each DR node.

Additional Information: