Skip to main content

SSH down

Comments

6 comments

  • cPanelMichael
    [QUOTE="JMGarc"a, post: 2531183, member: 834731">Feb 27 14:54:59 sv sshd[319]: fatal: Cannot bind any address. Feb 27 14:54:59 sv sshd[319]: error: Bind to port 22 on :: failed: Address already in use. Feb 27 14:54:59 sv sshd[319]: error: Bind to port 22 on 0.0.0.0 failed: Address already in use. Feb 27 14:54:32 sv sshd[32625]: fatal: Cannot bind any address. Feb 27 14:54:32 sv sshd[32625]: error: Bind to port 22 on :: failed: Address already in use.
    Hello, This suggests another service is already running on port 22. You can run the following command to see which process is utilizing the port: netstat -tulpn | grep :22
    Thank you.
    0
  • JMGarcía
    netstat -tulpn | grep :22 show this: [root@sv ~]# netstat -tulpn | grep :22 tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 32597/sshd tcp6 0 0 :::22 :::* LISTEN 32597/sshd [root@sv ~]#
    0
  • cPanelMichael
    Hello, In this case, it looks like SSH is in-fact running on port 22. Here's a response from one of our Technical Analysts on a similar issue opened via a support ticket. Check to see if this helps to solve the issue on your system: [QUOTE]The issue here is SSHD appears to be running as something of a "rogue" process. It looks like earlier today the SSHD process was forcefully killed with a KILL9 signal which could've come from a number of sources, and when SSHD was restarted after this it wasn't properly "registered. The process ID of SSHD wasn't recorded in systemd, and it wasn't marked as having been successfully restarted. Since systemd still thinks SSHD is down, it attempts to restart the service which then fails when it can't connect to port 22 because the "rogue" SSHD process is already using port 22:
    [QUOTE] You may also be able to try using out "safesshrestart" script which attempts to forcefully kill any existing SSH processes, and then restarting the SSHD server from WHM. To use the safesshrestart autofixer script you will need to log into your WHM and navigate to the following URL: ===== Restart Services > SSH Server (OpenSSH) and restart the SSH service. This should clear up the SSH process issues.
    Thank you.
    0
  • JMGarcía
    Hello, AutoFixer Execution Requesting script ... Done. Executing script ... Attempting to locate sshd binaries installed on the system ...
    Located /usr/sbin/sshd
    Done.
    Killing exisiting sshd processes...
    killed 32597 Done.
    configuring sshd to run on port 22
    Could not load host key: /etc/ssh/ssh_host_dsa_key /usr/sbin/sshd successfully started!
    root 26161 0.0 0.0 104508 1372 ? Ss 21:47 0:00 /usr/sbin/sshd -f /var/cpanel/safe_sshd
    Done. But still issue,... Service Version Status SSh down and if restart error,...
    0
  • cPanelMichael
    Hello, Could you open a support ticket using the link in my signature so we can take a closer look? Thank you.
    0
  • JMGarcía
    Your Support Request ID is: 9320465
    0

Please sign in to leave a comment.