Connecting to a Remote CVS Server via SSH on a non-standard TCP Port

Category: Software and Systems Engineering
Author: Sean O'Donnell
Sun, Nov. 5th, 2006 @ 5:36:51 (MST)

I have a CVS Repository hosted on my development server (, but it runs an SSH Server on a non-standard TCP port (22334), instead of the default/standard TCP port (22). I want to checkout some files from my CVS repository on that machine via SSH, but CVS doesn't allow you to specify an alternate TCP Port.

In order to connect to the CVS repository using via SSH client, I had to add an SSH configuration file to connect to the remote machine on the non-standard TCP port.

Since there was no existing SSH config file in my local directory tree, I created one.

# file: ~/.ssh/config
port 22334

Now, I can simply set my environment variables accordingly, and begin working with my remote machine as a CVS Server via SSH Tunnel, on a non-standard TCP Port.
cvs checkout project1

The example above would check-out the 'project1' from the CVS repository via SSH.

Due to security implications, I DO NOT suggest running SSH Servers that are exposed to the world (and sometimes internally even), on the standard/default low-port (22).

Copyleft (<) 1998-2019