Insights

Site Down but Server Responds to ping? Check If Apache or Nginx Actually Started

November 12, 2026
0:00
"I can ping the server, so it must be up." This is one of the most common wrong conclusions in hosting support. A customer opens a ticket saying their site is completely down, you ping the IP, get replies, SSH in without trouble, and assume the problem is somewhere else. But ping only proves the kernel is responding to ICMP packets. It says nothing about whether Apache, Nginx, or LiteSpeed is running, listening on port 80 or 443, or serving the right virtual host. A server can respond to ping all day while every website on it returns connection refused. Understanding why ping succeeds while HTTP fails is the first step to triaging "site down" tickets quickly instead of chasing the wrong layer.
Ping sends ICMP echo requests. The Linux kernel handles ICMP at the network layer, completely independent of any application. No web server needs to be running, no port needs to be open, and no firewall rule for HTTP needs to exist for ping to work. HTTP, on the other hand, requires a process (Apache, Nginx, or another web server) to be actively listening on a TCP port, typically 80 for HTTP and 443 for HTTPS. If that process crashed, was never started, or failed during a config reload, nothing answers TCP connections on those ports. The kernel is still alive, SSH still works, ping still replies, but browsers get "connection refused" or a timeout. This distinction matters because it changes where you look. Ping success means the network path and the OS are fine. It does not clear the web server, the firewall rules for HTTP ports, or the virtual host configuration.
SSH into the server. Check the service status. On systemd-based distributions (which covers most modern servers), the command depends on which web server is installed:
BASH
# For Nginx
systemctl status nginx

# For Apache on Debian/Ubuntu
systemctl status apache2

# For Apache on CentOS/RHEL/AlmaLinux
systemctl status httpd
You want to see active (running) in the output. If you see inactive (dead), failed, or activating, the web server is not serving requests. When the status shows failed, the next thing to check is the journal for the reason:
BASH
# Replace 'nginx' with 'apache2' or 'httpd' as needed
journalctl -u nginx --no-pager -n 50
Common reasons a web server fails to start or crashes mid-operation:
  • Configuration syntax error. Someone edited a vhost file, made a typo, and restarted the service. The restart failed, and now nothing is running. Both Apache and Nginx refuse to start if the config has a syntax error.
  • Port conflict. Another process already holds port 80 or 443. This happens more often than you would expect, especially on servers where both Apache and Nginx were installed at different times. One grabs the port, the other cannot bind to it and exits. A Plesk forum thread documents exactly this scenario: stopping Apache when Nginx is the reverse proxy in front of it, or vice versa, causes confusion about which process should own which port.
  • Resource exhaustion. The server ran out of memory, and the OOM killer terminated the web server process. Or the disk filled up and the server could not write to its error log or PID file.
  • Missing SSL certificate or key file. If a vhost references a certificate path that no longer exists (deleted, moved, or failed renewal), the web server will refuse to start entirely rather than serve that one site without TLS.
Even if systemctl status looks fine, confirm something is actually bound to the HTTP ports. The ss command (or netstat on older systems) shows listening sockets:
BASH
ss -tlnp | grep -E ':80|:443'
Sample output format when Nginx is listening:
TEXT
LISTEN  0  511  0.0.0.0:80   0.0.0.0:*  users:(("nginx",pid=1234,fd=6))
LISTEN  0  511  0.0.0.0:443  0.0.0.0:*  users:(("nginx",pid=1234,fd=7))
If the output is empty, nothing is listening. That confirms the web server is down or misconfigured, regardless of what systemctl status might say. There are edge cases where systemd reports the service as active but the process exited silently or is stuck in a state where it dropped its listening sockets. If something unexpected is listening, like a different process name than you expected, that points to a port conflict. You might find Apache holding port 80 when you expected Nginx, or a development server someone left running.
Process running, ports bound, but the site still times out from outside? Check the firewall. On many servers, iptables, nftables, firewalld, or a cloud provider's security group controls which ports accept inbound traffic. For firewalld (common on CentOS/AlmaLinux):
  • firewall-cmd --list-all shows active rules and open services/ports.
For iptables:
  • iptables -L -n lists current rules. Look for ACCEPT rules on ports 80 and 443, or DROP/REJECT rules that might block them.
Cloud providers often have a separate network-level firewall (security groups, network ACLs) that operates outside the OS. If the OS firewall looks fine but external connections still time out, check the cloud dashboard. A quick external test: from your local machine or another server, try curl -I http://server-ip or curl -I https://server-ip -k (the -k flag skips certificate verification). If curl gets "connection refused," the port is not open or nothing is listening. If curl hangs with no response, a firewall is likely dropping packets silently.
Sometimes the web server is running and the port is open, but the site still shows an error page, a default "welcome" page, or another domain's content. This means the virtual host (vhost) configuration is broken or missing for that domain. Common causes:
  • The vhost config file exists but is not enabled. On Nginx, the file might be in sites-available but not symlinked into sites-enabled. On Apache with Debian-style layouts, same pattern with a2ensite.
  • The ServerName (Apache) or server_name (Nginx) directive does not match the domain the visitor is requesting. The web server falls back to the default vhost, which might serve a different site entirely. This is closely related to how SNI and default SSL certificates work.
  • The document root path in the vhost points to a directory that does not exist or has wrong permissions.
  • PHP-FPM is down. The web server is running, but it cannot hand off .php requests to the PHP processor. The result is often a 502 Bad Gateway (Nginx) or 503 Service Unavailable (Apache with proxy to FPM). Check systemctl status php*-fpm to see if the PHP-FPM service is alive.
Test the config syntax before restarting:
  • Nginx: nginx -t
  • Apache: apachectl configtest or httpd -t
If the syntax test passes, a restart or reload should bring things back. If it fails, the error message usually points to the exact file and line number.
When you need to escalate, the note should tell the next engineer exactly where you stopped and what you found. Vague notes like "site is down, please check" waste time. Structure it around what you verified: If the web server process is dead: "Web server (nginx/httpd) is not running. systemctl status shows failed state. Journal shows [specific error, e.g., 'bind() to 0.0.0.0:80 failed: Address already in use']. Did not restart because [reason, e.g., config syntax test fails]. Needs review of [specific config file or port conflict]." If the port is blocked: "Nginx is running and listening on :80/:443 per ss -tlnp. External curl from [location] times out. OS-level iptables shows no ACCEPT rule for port 80. Likely firewall or security group issue. Customer does not have cloud dashboard access, needs infra team to check." If the vhost is broken: "Apache is running, port 80 responds, but domain example.com returns the default page instead of the customer's site. Vhost file exists at /etc/apache2/sites-available/example.com.conf but is not symlinked to sites-enabled. Did not enable it because the DocumentRoot path references a directory that does not exist. Need to confirm correct path with customer." Each of these tells the next person what layer is broken, what evidence you have, and what remains to be done. No guessing, no re-checking work already completed.
When a site is down but ping works, you are looking at three layers in order: process, port, config. Check if the web server process is running. Check if something is listening on 80/443. Check if the firewall allows traffic through. If all three pass, the problem is in the vhost config or a backend service like PHP-FPM. Each layer takes about 30 seconds to verify with the right command, and knowing which layer failed determines whether you fix it yourself or write an escalation note that actually moves the ticket forward.

Join My Newsletter & Get Updates!

Get notified whenever a new technical guide, server infrastructure breakdown, or personal reflection goes live, plus a curated weekly digest.