Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 5 of 5
  1. #1
    Member
    Join Date
    Jan 2004
    Posts
    755

    Default changing ssh port fails

    changed conf.apf and sshd_config to allow port 8669 or 10022 as the ssh port, restarted both services, can't connect. All works fine on port 22. After changing the above, port 22 doesn't work, so something is changing.

    Hints?

    centos 4.2, fresh install of OS and cpanel 10.xxx

  2. #2
    Member
    Join Date
    Aug 2003
    Location
    Canada
    Posts
    32

    Default

    I actually just did this morning. Double check that:

    -you entered the port correctly in the list
    -you entered the ssh port in the correct configuration variable

    in an attempt to be helpful, here is a properly configured configuration line for port 8669 for conf.apf.

    Code:
    IG_TCP_CPORTS="21,25,53,80,110,143,465,953,993,995,2082,2083,2084,2086,2087,2095,2096,3306,6666,7786,8669"
    ..remove ports as needed(note that the spaces were added by the forum).

    and...for sshd_config:

    Code:
    # The strategy used for options in the default sshd_config shipped with
    # OpenSSH is to specify options with their default value where
    # possible, but leave them commented.  Uncommented options change a
    # default value.
    
    Port 8669
    #Protocol 2,1
    #ListenAddress 0.0.0.0
    #ListenAddress ::


    I have tested this and it works -- so it definately works. You may need to double check in case you missed something. After changing the config, I flushed apf and restarted it, as well as restarting sshd.
    Last edited by WCrooks; 01-31-2006 at 02:02 PM.
    William Crooks
    Subliminal Development

  3. #3
    Member
    Join Date
    Jan 2004
    Posts
    755

    Default

    Here's mine. The only thing that changes is the port on the sshd_config file (both ports are in the proper section of apf):


    Code:
    Port 8669
    Protocol 2
    ListenAddress 208.29.xxx.xxx
    I've even shut off apf, so it's something with ssh itself. I have another box working on this port.... oh, I've got them backwards... it's working on the FRESH box, not on the RH9 box, if that matters.

    I've shutdown, restarted sshd and apf, tried commenting out the listen address and protocol. It's as if there's another firewall running besides apf, of which I'm not aware.

  4. #4
    Member
    Join Date
    Aug 2003
    Location
    Canada
    Posts
    32

    Default

    Perhaps check your running processes?You wouldn't have anything else configured for the port would you?
    William Crooks
    Subliminal Development

  5. #5
    Member
    Join Date
    Jan 2004
    Posts
    755

    Default

    Good thought... but doesn't look like it. Checking within WHM doesn't show anything.

Similar Threads & Tags
Similar threads

  1. Changing Port Kills SSH
    By elflaco in forum New User Questions
    Replies: 9
    Last Post: 01-04-2007, 09:49 PM
  2. 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
  3. Changing SSH port, binding to one IP... good or bad idea?
    By Gliebster in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 02-13-2006, 03:11 AM
  4. 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
  5. apache fails after changing the hostname
    By totalufo in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 03-31-2002, 09:26 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube