Community Forums
Connect with us on LinkedIn
  
+ Reply to Thread
Results 1 to 5 of 5
  1. #1
    Member
    Join Date
    Nov 2007
    Posts
    865

    Smile SSH port

    hello,

    how to check that which port is running on SSH

    i am using
    CENTOS 4.7 i686 on standard
    cPanel 11.24.4-R33609 - WHM 11.24.2 - X 3.9

    Thanks
    Nilesh

  2. #2
    cPanel Product Evangelist Infopro's Avatar
    Join Date
    May 2003
    Location
    Pennsylvania
    Posts
    7,893
    cPanel/Enkompass Access Level

    Root Administrator

    Lightbulb

    If you've never changed it, should be port 22.

    10 Tips for making your cPanel and WHM servers more secure should be helpful.

  3. #3
    Member arunsv84's Avatar
    Join Date
    Oct 2008
    Location
    India
    Posts
    129
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Type this command in shell...

    netstat -lnp |grep ssh

    Cheers!

  4. #4
    Member
    Join Date
    Nov 2007
    Posts
    865

    Default

    hi

    thanks it is working

    i have 2 more questions

    1. can i check the same using WHM ??

    2. now let me know how to change default port 22 & which new port should use ??

    Thanks
    Nilesh

  5. #5
    Member rhenderson's Avatar
    Join Date
    Apr 2005
    Location
    Oklahoma
    Posts
    742

    Default

    nano /etc/ssh/sshd_config

    Code:
    Change
    #Port 22
    to
    Port 3474
    Of course I just made up 3474, pick a number of a port that is not being used, be sure to open your firewall and remove the comment character #. If your not sure about a port conflict, i.e. using a port already for something else look at the ports already open in your firewall and choose one that is not there, or search on here for firewall ports and there should be a list, again choose one not in use.

    More suggestions

    Code:
    Protocol 2
    ListenAddress 192.168.0.1
    Make the listen address one of your IP's the 192.168.0.1 was just an example. This will limit what IP can ssh in which is a little more secure Instead of allowing any of your IP's to be able to ssh.

    You cpuld even make an A entry in your DNS zone ie ssh.domain.com and if you ever need to change your IP you would not have to notify your clients (because they are using ssh.domain.com) you could simply change the A record.
    Last edited by rhenderson; 02-11-2009 at 12:02 AM.
    Regards,
    Randy
    Affordable Web Hosting
    _________________________

Similar Threads & Tags
Similar threads

  1. Change SSH Port
    By polkocholo in forum Security
    Replies: 9
    Last Post: 03-19-2011, 01:44 AM
  2. SSH Port
    By Chriz1977 in forum cPanel and WHM Discussions
    Replies: 11
    Last Post: 11-25-2006, 07:07 AM
  3. changed ssh port - cant login on new port
    By 4u123 in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 03-21-2006, 10:02 AM
  4. SSH port
    By WizCraker in forum cPanel and WHM Discussions
    Replies: 7
    Last Post: 01-22-2005, 05:01 PM
  5. Custom ssh port for CPanel SSH client
    By yaax in forum cPanel and WHM Discussions
    Replies: 13
    Last Post: 10-24-2004, 12:22 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube