Business Management | Editors Column | Hosting Customers | Interviews & PR | Marketing/Advertising | Online Marketing/SEO | Web Hosting | Web Hosting Reviews

Web Hosting Reviews and Tutorials

Fully Managed Dedicated Servers from Liquidweb Cheap - Click here

Having SSH respond on more than one port on Red Hat Linux

by WHRKIT on April 4, 2006

Having SSH listen on more than one port on Red Hat Linux

The default port for SSH to listen on is port 22. Sometimes webmasters or system administrators need to have access on either complete different port or to have SSH to listen on two ports at the same time. The following steps explain how this can be done.
 
The file that holds the current SSH port settings can be found at:
 
/etc/ssh/sshd_config
 
Log on to your server via SSH and switch to the root user. Open this file in your favorite text editor and either change/remove the setting for port 22 or add the additional port setting in a new line. Example:
 
Port 22

Port 435
 
Save the file and then restart SSH:
 
service sshd restart
 
Now you need to verify that SSH is listening on the new port:
 
netstat -an | grep 435
 
It is highly recommended to use a port that is not in use by popular applications on the Internet. A random port number should be chosen for better security. If you are running a firewall on your server you will also need to adjust the firewall rules to allow the new port to be accessible from the Internet.

© 2006 – Web Hosting Resource Kit

Related posts:

  1. How to check the port speed and duplex setting (Linux)?
  2. Linux Tutorial: How to change the IP ADDRESS on a Linux machine
  3. Apache Webserver – A quick tutorial for new Admins
  4. How to Secure your Dedicated Server (RedHat Linux + Cpanel)
  5. Which Firewall Ports are needed to be open on a cPanel/WHM Server
  6. How to kick an unauthorized user off a SSH session and Linux server?
  7. Iptables Firewall – A basic introduction

Leave a Comment

Previous post:

Next post: