How to Tell If Slow Uptime Checks Are Your Server or the Network
Most "down" alerts are not downtime. When you get an uptime monitoring false positive, the usual cause is either the checker's vantage point or its timeout budget, not your server. The fast way to tell them apart is to reproduce the check yourself from a host you control and compare what your server logs against what the monitor reported.
Below is the mechanics of how a checker decides "down," why that decision differs from what a real user sees, and the commands that separate a genuine outage from a monitoring false positive.
What the checker actually does, and where it can go wrong
Almost every uptime checker is doing one of three things: a TCP connect to a port, an HTTP request for a URL and a check of the status code, or a keyword match on the response body. Each has a failure mode that looks identical in your alert feed.
A TCP check only proves something accepted a connection on that port from that IP at that moment. A firewall rule that drops packets from the checker's address range, a rate limiter, or a fail2ban-style ban after repeated probes will all produce a clean "connection refused" or "timed out" with your application perfectly healthy. HTTP checks add DNS resolution, TLS handshake, and response time to the chain, so a slow DNS answer or a certificate chain problem at one resolver shows up as downtime even though the site serves fine.
The single most common structural mistake is a short timeout. If the checker gives up after a couple of seconds and your origin sometimes takes longer under load, you will collect alerts that correlate with traffic, not with outages. The same applies to redirects: if the checker does not follow them, a 301 to a canonical host reads as a failure.
Reproduce the check before you believe the alert
Start by asking your server what it saw. For an HTTP check, the request line and the user agent in your access log tell you whether the probe arrived at all. Checkers usually send a distinctive user agent, and many send a custom header you can configure.
grep -i "uptime\|monitor\|check" /var/log/nginx/access.log | tail -n 20
The shape of the output matters more than the exact text. You want to see whether requests from the checker appear around the alert time, what status code you returned, and how long the request took. If there are no entries at all at the alert timestamp, the probe never reached your server, which points at DNS, routing, or a firewall upstream. If entries are present with a 200 and a normal response time, the monitor's verdict is wrong and you are looking at a false positive.
Next, reproduce the request from outside your own network, because a check from your laptop proves little. From a host in a different network, run the same request the monitor makes and watch the timing:
curl -sS -o /dev/null \
-w 'dns=%{time_namelookup} connect=%{time_connect} tls=%{time_appconnect} first_byte=%{time_starttransfer} total=%{time_total} code=%{http_code}\n' \
https://example.com/health
Read the breakdown. A large time_namelookup means DNS is the problem and the server is not. A large time_connect means the TCP handshake is slow, which is routing or a saturated listen backlog. A large time_appconnect points at TLS, often an OCSP fetch or a slow certificate chain. A large gap between time_starttransfer and time_total means your application is slow to generate the body, which is a real problem but not necessarily downtime. Repeat the command a few times and from more than one location before drawing conclusions.
Separating a routing or DNS problem from a server problem
If the probe never reaches your server, work backwards along the path. Resolve the name the way the checker would, from a resolver outside your network, and compare the answer with what you expect:
dig +short example.com A
dig +short example.com AAAA
dig +trace example.com | tail -n 20
Look for a stale A record pointing at a decommissioned address, an AAAA record that resolves to an IPv6 address your host does not actually serve, or a split-horizon setup where the public answer differs from the internal one. A common false positive is a monitor that prefers IPv6 while your origin only listens on IPv4, so the checker times out and your IPv4 users are fine.
For routing, a traceroute from a host near the checker toward your address shows where packets stop. You are looking for a hop that consistently drops or a path that never reaches your network edge. If the last responding hop is your provider's edge and not your server, the problem is upstream of you. If packets reach your host but no SYN-ACK comes back, check your firewall and any connection rate limits; a monitor polling every few seconds from a fixed address range can trip a per-IP limit that a human never would.
Fixing monitoring false positives in the config
Once you know which layer is failing, adjust the check rather than the server. Give the probe a longer timeout than your worst healthy response, follow redirects, and check a lightweight endpoint that exercises the application without hitting the database or a cache miss. A dedicated health path that returns a small fixed body is far more stable than checking the homepage.
On the server side, make sure the probe is identifiable and not throttled. A log format that records the request time and upstream time lets you correlate alerts with real latency later. If you run a reverse proxy, confirm it is not buffering the health response in a way that delays the first byte past the checker's timeout.
Finally, run the check from at least two independent locations and alert only when both agree. A single vantage point cannot distinguish your outage from its own network problem, and most false positives disappear the moment you require corroboration. When locations disagree, treat it as a routing or DNS incident and investigate the path, not the application.
What to do next: pick your noisiest alert, pull the matching access log entries for its timestamp, and run the curl timing command from a host outside your network. If the log shows a healthy response, raise the timeout and add a second checker location before you touch the server. If the log shows nothing, chase DNS and routing first. Keep a short note of what each alert turned out to be, so the next one is faster to classify.
