{"id":3513,"date":"2010-02-27T18:30:51","date_gmt":"2010-02-27T23:30:51","guid":{"rendered":"http:\/\/underhost.com\/blog\/?p=3513"},"modified":"2026-10-23T09:55:02","modified_gmt":"2026-10-23T13:55:02","slug":"sshd-has-failed-please-contact-the-sysadmin","status":"publish","type":"post","link":"https:\/\/underhost.com\/blog\/sshd-has-failed-please-contact-the-sysadmin\/","title":{"rendered":"cPanel &#8220;sshd has failed, please contact the sysadmin&#8221;: Causes and Fixes"},"content":{"rendered":"<div class=\"uh-blog-hero\" style=\"margin:0 0 40px;text-align:center;padding:48px 24px;border-radius:20px;background:linear-gradient(135deg,#0D1F3C 0%,#125A8A 58%,#176EA5 100%);color:#ffffff;box-shadow:0 20px 40px -15px rgba(13,31,60,0.28);position:relative;overflow:hidden;\">\n<div style=\"display:inline-flex;align-items:center;gap:8px;padding:7px 14px;margin-bottom:16px;border:1px solid rgba(0,212,255,0.32);border-radius:999px;color:#DFF8FF;font-size:12px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;background:rgba(0,212,255,0.10);\"><i class=\"fas fa-sliders-h\" style=\"color:#00D4FF;\"><\/i> Control Panels<\/div>\n<h1 style=\"color:#ffffff;font-size:clamp(32px,5vw,46px);line-height:1.12;margin:0 0 14px;font-weight:800;\">cPanel &#8220;sshd has failed, please contact the sysadmin&#8221;: Causes and Fixes<\/h1>\n<\/div>\n<div class=\"uh-blog-excerpt\" style=\"border-left:4px solid #00D4FF;padding:18px 20px;margin:0 0 34px;background:#F8FAFC;color:#1F2937;border-radius:0 14px 14px 0;box-shadow:0 8px 28px rgba(13,31,60,0.08);line-height:1.75;\"><strong style=\"color:#0D1F3C;\">Short answer:<\/strong> This alert comes from cPanel&#8217;s service monitor (chkservd) when it cannot reach the SSH service. First check whether SSH really is down: <code>systemctl status sshd<\/code>. If it is stopped, test the configuration with <code>sshd -t<\/code>, fix the error it shows, and start it with <code>\/scripts\/restartsrv_sshd<\/code>. If SSH works but the alert continues, the monitor is probably checking the wrong port after a port change. Use your provider&#8217;s console if you cannot log in at all.<\/div>\n<nav aria-label=\"Table of contents\" class=\"uh-toc\" style=\"background:#ffffff;border:1px solid #E5E7EB;border-radius:16px;padding:20px 22px;margin:0 0 34px;box-shadow:0 4px 12px rgba(13,31,60,0.08);\">\n<div style=\"font-size:12px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;color:#176EA5;margin-bottom:10px;\"><i class=\"fas fa-list\" style=\"color:#00D4FF;\"><\/i> In this guide<\/div>\n<ol style=\"margin:0;padding-left:20px;columns:2 260px;column-gap:28px;line-height:1.9;\">\n<li><a href=\"#what-the-alert-means\" style=\"color:#176EA5;text-decoration:none;font-weight:600;\">What the alert means<\/a><\/li>\n<li><a href=\"#step-1-get-access-to-the-server\" style=\"color:#176EA5;text-decoration:none;font-weight:600;\">Step 1: get access to the server<\/a><\/li>\n<li><a href=\"#step-2-check-the-ssh-service\" style=\"color:#176EA5;text-decoration:none;font-weight:600;\">Step 2: check the SSH service<\/a><\/li>\n<li><a href=\"#step-3-fix-a-stopped-ssh-service\" style=\"color:#176EA5;text-decoration:none;font-weight:600;\">Step 3: fix a stopped SSH service<\/a><\/li>\n<li><a href=\"#step-4-fix-false-alerts-after-a-port-change\" style=\"color:#176EA5;text-decoration:none;font-weight:600;\">Step 4: fix false alerts after a port change<\/a><\/li>\n<li><a href=\"#change-the-ssh-port-safely\" style=\"color:#176EA5;text-decoration:none;font-weight:600;\">Change the SSH port safely<\/a><\/li>\n<li><a href=\"#prevent-ssh-lockouts\" style=\"color:#176EA5;text-decoration:none;font-weight:600;\">Prevent SSH lockouts<\/a><\/li>\n<\/ol>\n<\/nav>\n<div class=\"uh-post-content\" style=\"color:#1F2937;font-size:16px;line-height:1.75;\">\n<h2 id=\"what-the-alert-means\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-info-circle\" style=\"color:#00D4FF;\"><\/i> What the alert means<\/h2>\n<p style=\"margin:0 0 18px;\">cPanel runs a service monitor called <strong>chkservd<\/strong>. Every few minutes it checks that services such as Apache, Exim, MySQL and SSH respond. When a check fails, it tries to restart the service and emails the server contact with a message such as <em>sshd has failed, please contact the sysadmin<\/em>. It can mean that SSH really stopped, or that the check itself fails.<\/p>\n<h2 id=\"step-1-get-access-to-the-server\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-terminal\" style=\"color:#00D4FF;\"><\/i> Step 1: get access to the server<\/h2>\n<p style=\"margin:0 0 18px;\">If you can still log in over SSH, use that. If not, use the console in your provider&#8217;s control panel (VNC, KVM or IPMI). Console access does not depend on SSH, so it works even when sshd is down. WHM&#8217;s <strong>Terminal<\/strong> page is another option while WHM still works.<\/p>\n<h2 id=\"step-2-check-the-ssh-service\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-terminal\" style=\"color:#00D4FF;\"><\/i> Step 2: check the SSH service<\/h2>\n<pre style=\"background:#0D1F3C;color:#EAF6FF;padding:18px 20px;border-radius:14px;overflow-x:auto;line-height:1.7;font-size:15px;\"><code>systemctl status sshd --no-pager\njournalctl -u sshd -n 50 --no-pager     # recent SSH log lines\nss -tlnp | grep sshd                    # which port SSH listens on<\/code><\/pre>\n<p style=\"margin:0 0 18px;\">If the service is <strong>active (running)<\/strong> and listens on the port you expect, SSH is fine and the alert is about the monitor. Go to Step 4. If it is stopped or failed, continue with Step 3.<\/p>\n<h2 id=\"step-3-fix-a-stopped-ssh-service\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-terminal\" style=\"color:#00D4FF;\"><\/i> Step 3: fix a stopped SSH service<\/h2>\n<p style=\"margin:0 0 18px;\">The most common cause is a mistake in <code>\/etc\/ssh\/sshd_config<\/code>, often after changing the port or login settings. Test the file:<\/p>\n<pre style=\"background:#0D1F3C;color:#EAF6FF;padding:18px 20px;border-radius:14px;overflow-x:auto;line-height:1.7;font-size:15px;\"><code>sshd -t<\/code><\/pre>\n<p style=\"margin:0 0 18px;\">No output means the file is valid. Otherwise, the message names the line with the problem. Fix it, then restart SSH:<\/p>\n<pre style=\"background:#0D1F3C;color:#EAF6FF;padding:18px 20px;border-radius:14px;overflow-x:auto;line-height:1.7;font-size:15px;\"><code>\/scripts\/restartsrv_sshd\n# or\nsystemctl restart sshd<\/code><\/pre>\n<p style=\"margin:0 0 18px;\">Keep your current session open, and test a new login in a second window before you close it. Other causes include a full disk (<code>df -h<\/code>), missing host keys (regenerate them with <code>ssh-keygen -A<\/code>), or another program using the SSH port.<\/p>\n<h2 id=\"step-4-fix-false-alerts-after-a-port-change\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-terminal\" style=\"color:#00D4FF;\"><\/i> Step 4: fix false alerts after a port change<\/h2>\n<p style=\"margin:0 0 18px;\">If you moved SSH to a different port, the monitor and the firewall must both know about it:<\/p>\n<ol style=\"margin:0 0 24px;padding-left:22px;\">\n<li style=\"margin:0 0 8px;\">Open the new port in the firewall before you restart SSH. With CSF, add it to <code>TCP_IN<\/code> in <code>\/etc\/csf\/csf.conf<\/code> and run <code>csf -r<\/code>.<\/li>\n<li style=\"margin:0 0 8px;\">In WHM, open <strong>Service Configuration &gt; Service Manager<\/strong> and check that monitoring is enabled for the SSH daemon.<\/li>\n<li style=\"margin:0 0 8px;\">Read the monitor&#8217;s log to see why the check fails: <code>tail -n 50 \/var\/log\/chkservd.log<\/code>.<\/li>\n<li style=\"margin:0 0 8px;\">If the check still uses the old port, restart the monitor with <code>\/scripts\/restartsrv_chkservd<\/code> after the SSH change, and contact support if the alerts continue.<\/li>\n<\/ol>\n<p style=\"margin:0 0 18px;\">Our <a href=\"https:\/\/underhost.com\/blog\/how-to-install-and-configure-csf-firewall-on-your-server\/\">CSF firewall guide<\/a> shows how to open ports safely.<\/p>\n<h2 id=\"change-the-ssh-port-safely\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-terminal\" style=\"color:#00D4FF;\"><\/i> Change the SSH port safely<\/h2>\n<ol style=\"margin:0 0 24px;padding-left:22px;\">\n<li style=\"margin:0 0 8px;\">Open the new port in the firewall first.<\/li>\n<li style=\"margin:0 0 8px;\">Edit <code>\/etc\/ssh\/sshd_config<\/code> and set <code>Port 2222<\/code> (or your chosen port).<\/li>\n<li style=\"margin:0 0 8px;\">Run <code>sshd -t<\/code> to test the file.<\/li>\n<li style=\"margin:0 0 8px;\">Restart SSH with <code>\/scripts\/restartsrv_sshd<\/code>.<\/li>\n<li style=\"margin:0 0 8px;\">In a second window, log in with <code>ssh -p 2222 root@your-server-ip<\/code>.<\/li>\n<li style=\"margin:0 0 8px;\">Only when the new login works, close the old port in the firewall.<\/li>\n<\/ol>\n<p style=\"margin:0 0 18px;\">A different port reduces automated login attempts, but it is not real protection on its own. SSH keys and turning off password logins matter more.<\/p>\n<h2 id=\"prevent-ssh-lockouts\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-terminal\" style=\"color:#00D4FF;\"><\/i> Prevent SSH lockouts<\/h2>\n<ul style=\"list-style:none;padding-left:0;\">\n<li style=\"margin:0 0 8px;\">\u2713 Always test <code>sshd -t<\/code> before restarting SSH.<\/li>\n<li style=\"margin:0 0 8px;\">\u2713 Keep one session open while you test changes in another.<\/li>\n<li style=\"margin:0 0 8px;\">\u2713 Make sure you know how to reach the console in your provider&#8217;s control panel.<\/li>\n<li style=\"margin:0 0 8px;\">\u2713 Add your own IP address to the firewall allow list, so login protection never blocks you.<\/li>\n<li style=\"margin:0 0 8px;\">\u2713 Use the safe SSH practices in our <a href=\"https:\/\/underhost.com\/blog\/common-ssh-commands-or-linux-shell-commands\/\">SSH commands guide<\/a>.<\/li>\n<\/ul>\n<div aria-hidden=\"true\" class=\"uh-section-divider\" style=\"width:min(100% - 32px, 1080px);margin:44px auto;display:grid;grid-template-columns:1fr 32px 1fr;align-items:center;gap:18px;pointer-events:none;\"><span style=\"height:1px;background:linear-gradient(90deg,transparent,rgba(0,212,255,0.40),rgba(23,110,165,0.24),transparent);\"><\/span><img alt=\"\" decoding=\"async\" height=\"32\" loading=\"lazy\" src=\"https:\/\/cdn.underhost.com\/android-chrome-192x192.webp\" style=\"width:32px;height:32px;display:block;border-radius:8px;filter:drop-shadow(0 0 14px rgba(0,212,255,0.30));\" width=\"32\"\/><span style=\"height:1px;background:linear-gradient(90deg,transparent,rgba(23,110,165,0.24),rgba(0,212,255,0.40),transparent);\"><\/span><\/div>\n<\/div>\n<div class=\"uh-blog-cta\" style=\"background:linear-gradient(135deg,#0D1F3C 0%,#125A8A 58%,#176EA5 100%);color:#ffffff;padding:36px 24px;border-radius:20px;text-align:center;margin:44px 0;box-shadow:0 20px 40px -15px rgba(13,31,60,0.32);\">\n<h2 style=\"margin:0 0 12px;font-size:28px;line-height:1.25;color:#ffffff;\">Need help with this?<\/h2>\n<p style=\"font-size:17px;margin:0 auto 22px;color:#EAF6FF;max-width:720px;line-height:1.7;\">Locked out of your server? Our team can restore access and harden SSH for you.<\/p>\n<p><a href=\"https:\/\/underhost.com\/server-management.php\" style=\"background:linear-gradient(90deg,#00D4FF,#0077FF);color:#ffffff;padding:13px 28px;border-radius:10px;text-decoration:none;font-weight:800;display:inline-block;margin:8px;\">See server management plans<\/a><a href=\"https:\/\/customerpanel.ca\/client\/\" style=\"background:transparent;color:#ffffff;padding:12px 28px;border-radius:10px;text-decoration:none;font-weight:800;display:inline-block;margin:8px;border:1px solid rgba(255,255,255,0.32);\">Contact @CustomerPanel<\/a><\/div>\n<div class=\"uh-faq-section\" id=\"faq\" style=\"margin:34px 0;scroll-margin-top:90px;\">\n<h2 style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:0 0 18px;border-bottom:2px solid rgba(0,212,255,0.22);padding-bottom:10px;\">Frequently asked questions<\/h2>\n<div style=\"margin-top:18px;background:#F8FAFC;padding:18px 20px;border-radius:14px;border:1px solid rgba(23,110,165,0.14);\">\n<h3 style=\"color:#0D1F3C;margin:0 0 8px;font-size:19px;\">What does &#8220;sshd has failed, please contact the sysadmin&#8221; mean?<\/h3>\n<p style=\"margin:0;color:#1F2937;line-height:1.7;\">cPanel&#8217;s service monitor could not reach the SSH service. Either SSH stopped, or the monitor&#8217;s check fails, for example after a port change.<\/p>\n<\/div>\n<div style=\"margin-top:18px;background:#F8FAFC;padding:18px 20px;border-radius:14px;border:1px solid rgba(23,110,165,0.14);\">\n<h3 style=\"color:#0D1F3C;margin:0 0 8px;font-size:19px;\">How do I restart SSH on a cPanel server?<\/h3>\n<p style=\"margin:0;color:#1F2937;line-height:1.7;\">Run \/scripts\/restartsrv_sshd or systemctl restart sshd as root, after testing the configuration with sshd -t.<\/p>\n<\/div>\n<div style=\"margin-top:18px;background:#F8FAFC;padding:18px 20px;border-radius:14px;border:1px solid rgba(23,110,165,0.14);\">\n<h3 style=\"color:#0D1F3C;margin:0 0 8px;font-size:19px;\">How can I fix SSH if I cannot log in?<\/h3>\n<p style=\"margin:0;color:#1F2937;line-height:1.7;\">Use the console in your provider&#8217;s control panel, or WHM&#8217;s Terminal page, to fix the configuration and restart SSH.<\/p>\n<\/div>\n<div style=\"margin-top:18px;background:#F8FAFC;padding:18px 20px;border-radius:14px;border:1px solid rgba(23,110,165,0.14);\">\n<h3 style=\"color:#0D1F3C;margin:0 0 8px;font-size:19px;\">Is it safe to change the SSH port?<\/h3>\n<p style=\"margin:0;color:#1F2937;line-height:1.7;\">Yes, if you open the new port in the firewall first and test a login before closing the old one.<\/p>\n<\/div>\n<div style=\"margin-top:18px;background:#F8FAFC;padding:18px 20px;border-radius:14px;border:1px solid rgba(23,110,165,0.14);\">\n<h3 style=\"color:#0D1F3C;margin:0 0 8px;font-size:19px;\">Where are the cPanel service monitor logs?<\/h3>\n<p style=\"margin:0;color:#1F2937;line-height:1.7;\">In \/var\/log\/chkservd.log.<\/p>\n<\/div>\n<\/div>\n<p><!-- uh-related-start --><\/p>\n<div style=\"background:#F4F8FC;border:1px solid #DCE7F3;border-radius:14px;padding:18px 22px;margin:32px 0 8px;\">\n<h2 style=\"margin:0 0 12px;font-size:22px;\">Related guides<\/h2>\n<ul style=\"margin:0;padding-left:20px;\">\n<li style=\"margin:0 0 8px;\"><a href=\"https:\/\/underhost.com\/blog\/how-to-optimize-php-performance-in-cpanel-with-multiphp-manager-cloudlinux-php-selector\/\">How to Optimize PHP Performance in cPanel with MultiPHP Manager &amp; CloudLinux PHP Selector<\/a><\/li>\n<li style=\"margin:0 0 8px;\"><a href=\"https:\/\/underhost.com\/blog\/almalinux-9-with-cpanel-mysql-8-to-mariadb-10-11-guide\/\">AlmaLinux 9 with cPanel: MySQL 8 to MariaDB 10.11 Guide<\/a><\/li>\n<li style=\"margin:0 0 8px;\"><a href=\"https:\/\/underhost.com\/blog\/cpanel-backup-and-restore-a-domain-account-via-ssh\/\">How to Back Up and Restore a cPanel Account Over SSH<\/a><\/li>\n<li style=\"margin:0 0 8px;\"><a href=\"https:\/\/underhost.com\/blog\/how-to-fix-usr-bin-crontab-permissions-are-wrong-error-in-cpanel\/\">How to Fix &#8220;\/usr\/bin\/crontab Permissions Are Wrong&#8221; Error in cPanel<\/a><\/li>\n<li style=\"margin:0 0 8px;\"><a href=\"https:\/\/underhost.com\/blog\/how-to-uninstall-cloudlinux-from-cpanel\/\">How to Install or Uninstall CloudLinux from cPanel (Updated Guide)<\/a><\/li>\n<\/ul>\n<\/div>\n<p><!-- uh-related-end --><br \/>\n<script type=\"application\/ld+json\">{\"@context\": \"https:\/\/schema.org\", \"@type\": \"FAQPage\", \"mainEntity\": [{\"@type\": \"Question\", \"name\": \"What does \\\"sshd has failed, please contact the sysadmin\\\" mean?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"cPanel's service monitor could not reach the SSH service. Either SSH stopped, or the monitor's check fails, for example after a port change.\"}}, {\"@type\": \"Question\", \"name\": \"How do I restart SSH on a cPanel server?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"Run \/scripts\/restartsrv_sshd or systemctl restart sshd as root, after testing the configuration with sshd -t.\"}}, {\"@type\": \"Question\", \"name\": \"How can I fix SSH if I cannot log in?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"Use the console in your provider's control panel, or WHM's Terminal page, to fix the configuration and restart SSH.\"}}, {\"@type\": \"Question\", \"name\": \"Is it safe to change the SSH port?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"Yes, if you open the new port in the firewall first and test a login before closing the old one.\"}}, {\"@type\": \"Question\", \"name\": \"Where are the cPanel service monitor logs?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"In \/var\/log\/chkservd.log.\"}}]}<\/script><\/p>\n<h2 id=\"sources\" style=\"color:#0D1F3C;font-size:28px;line-height:1.25;margin:34px 0 14px;scroll-margin-top:90px;\"><i class=\"fas fa-book\" style=\"color:#00D4FF;\"><\/i> Sources<\/h2>\n<ul style=\"margin:0 0 24px;padding-left:22px;\">\n<li style=\"margin:0 0 8px;\"><a href=\"https:\/\/docs.cpanel.net\/whm\/service-configuration\/service-manager\/\">cPanel documentation: Service Manager<\/a><\/li>\n<li style=\"margin:0 0 8px;\"><a href=\"https:\/\/man.openbsd.org\/sshd_config\">OpenSSH manual: sshd_config<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>This alert comes from cPanel&#8217;s service monitor (chkservd) when it cannot reach the SSH service. First check whether SSH really is down: systemctl status sshd. If it is stopped, test the configuration with sshd -t, fix the error it shows, and start it with \/scripts\/restartsrv_sshd. If SSH works but the alert continues, the monitor is probably checking the wrong port after a port change. Use your provider&#8217;s console if you cannot log in at all.<\/p>\n","protected":false},"author":1,"featured_media":4853,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,202,25],"tags":[108,137,115,109],"class_list":["post-3513","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-control-panels","category-cpanel-whm","category-linux","tag-tag-cpanel","tag-tag-firewall","tag-tag-linux-server","tag-tag-whm"],"_links":{"self":[{"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/posts\/3513","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/comments?post=3513"}],"version-history":[{"count":8,"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/posts\/3513\/revisions"}],"predecessor-version":[{"id":7019,"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/posts\/3513\/revisions\/7019"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/media\/4853"}],"wp:attachment":[{"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/media?parent=3513"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/categories?post=3513"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/underhost.com\/blog\/wp-json\/wp\/v2\/tags?post=3513"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}