Just update your sshd_config file and then reloading the new configuration.
Use the procedure below to change the port that sshd is listening on to 69:
1. From your terminal session, edit /etc/ssh/sshd_config
- Code: Select all
[root@local]# vi /etc/ssh/sshd_config2
2. Look for the following line:
- Code: Select all
#Port 22
3. Change the line so it looks like this:
- Code: Select all
Port 69
4. Save and close the file
5. Load the new configuration by using the RedHat service command
- Code: Select all
[root@local]# service sshd reload
Note: you may immediately lose connectivity to your server on the open ssh session you are currently running (I didn't lose connection, but i was not able to start a new one with the old port)
6. Test the connection
- Code: Select all
[root@local]# ssh your.domain.com -p 69
Take note of the -p 69 flag used when connecting to the server. If you are using OS X or a Linux desktop system like Mandriva or Ubuntu, you'll need to specify the port number when connecting. If you're using PuTTy on Windows, you can specify the port number in the profile for you connection and then re-save the profile using the new port.
