The only agent that thinks for itself

Autonomous Monitoring with self-learning AI built-in, operating independently across your entire stack.

Unlimited Metrics & Logs
Machine learning & MCP
5% CPU, 150MB RAM
3GB disk, >1 year retention
800+ integrations, zero config
Dashboards, alerts out of the box
> Discover Netdata Agents

Centralized metrics streaming and storage

Aggregate metrics from multiple agents into centralized Parent nodes for unified monitoring across your infrastructure.

Stream from unlimited agents
Long-term data retention
High availability clustering
Data replication & backup
Scalable architecture
Enterprise-grade security
> Learn about Parents

Fully managed cloud platform

Access your monitoring data from anywhere with our SaaS platform. No infrastructure to manage, automatic updates, and global availability.

Zero infrastructure management
99.9% uptime SLA
Global data centers
Automatic updates & patches
Enterprise SSO & RBAC
SOC2 & ISO certified
> Explore Netdata Cloud

Deploy Netdata Cloud in your infrastructure

Run the full Netdata Cloud platform on-premises for complete data sovereignty and compliance with your security policies.

Complete data sovereignty
Air-gapped deployment
Custom compliance controls
Private network integration
Dedicated support team
Kubernetes & Docker support
> Learn about Cloud On-Premises

Powerful, intuitive monitoring interface

Modern, responsive UI built for real-time troubleshooting with customizable dashboards and advanced visualization capabilities.

Real-time chart updates
Customizable dashboards
Dark & light themes
Advanced filtering & search
Responsive on all devices
Collaboration features
> Explore Netdata UI

Monitor on the go

Native iOS and Android apps bring full monitoring capabilities to your mobile device with real-time alerts and notifications.

iOS & Android apps
Push notifications
Touch-optimized interface
Offline data access
Biometric authentication
Widget support
> Download apps

The future of infrastructure observability

See our strategic direction across AI-native observability, full-stack signals, operational intelligence, and enterprise platform maturity.

AI-native observability
Full-stack signal coverage
Operational intelligence
Enterprise platform maturity
Agent releases every 6 weeks
Cloud continuous delivery
> Explore Product Roadmap

Best energy efficiency

True real-time per-second

100% automated zero config

Centralized observability

Multi-year retention

High availability built-in

Zero maintenance

Always up-to-date

Enterprise security

Complete data control

Air-gap ready

Compliance certified

Millisecond responsiveness

Infinite zoom & pan

Works on any device

Native performance

Instant alerts

Monitor anywhere

AI-native observability

Continuous delivery

Open source foundation

80% Faster Incident Resolution

AI-powered troubleshooting from detection, to root cause and blast radius identification, to reporting.

True Real-Time and Simple, even at Scale

Linearly and infinitely scalable full-stack observability, that can be deployed even mid-crisis.

90% Cost Reduction, Full Fidelity

Instead of centralizing the data, Netdata distributes the code, eliminating pipelines and complexity.

See and Map Your Entire Network

Live topology, flow analytics, and SNMP device and trap monitoring — unified with your full-stack observability.

Control Without Surrender

SOC 2 Type 2 certified with every metric kept on your infrastructure.

Integrations

800+ collectors and notification channels, auto-discovered and ready out of the box.

800+ data collectors
Auto-discovery & zero config
Cloud, infra, app protocols
Notifications out of the box
> Explore integrations
Real Results
46% Cost Reduction

Reduced monitoring costs by 46% while cutting staff overhead by 67%.

— Leonardo Antunez, Codyas

Zero Pipeline

No data shipping. No central storage costs. Query at the edge.

From Our Users
"Out-of-the-Box"

So many out-of-the-box features! I mostly don't have to develop anything.

— Simon Beginn, LANCOM Systems

No Query Language

Point-and-click troubleshooting. No PromQL, no LogQL, no learning curve.

Enterprise Ready
67% Less Staff, 46% Cost Cut

Enterprise efficiency without enterprise complexity—real ROI from day one.

— Leonardo Antunez, Codyas

SOC 2 Type 2 Certified

Zero data egress. Only metadata reaches the cloud. Your metrics stay on your infrastructure.

Full Coverage
800+ Collectors

Auto-discovered and configured. No manual setup required.

Any Notification Channel

Slack, PagerDuty, Teams, email, webhooks—all built-in.

Built for the People Who Get Paged

Because 3am alerts deserve instant answers, not hour-long hunts.

Every Industry Has Rules. We Master Them.

See how healthcare, finance, and government teams cut monitoring costs 90% while staying audit-ready.

Monitor Any Technology. Configure Nothing.

Install the agent. It already knows your stack.
From Our Users
"A Rare Unicorn"

Netdata gives more than you invest in it. A rare unicorn that obeys the Pareto rule.

— Eduard Porquet Mateu, TMB Barcelona

99% Downtime Reduction

Reduced website downtime by 99% and cloud bill by 30% using Netdata alerts.

— Falkland Islands Government

Real Savings
30% Cloud Cost Reduction

Optimized resource allocation based on Netdata alerts cut cloud spending by 30%.

— Falkland Islands Government

46% Cost Cut

Reduced monitoring staff by 67% while cutting operational costs by 46%.

— Codyas

Real Coverage
"Plugin for Everything"

Netdata has agent capacity or a plugin for everything, including Windows and Kubernetes.

— Eduard Porquet Mateu, TMB Barcelona

"Out-of-the-Box"

So many out-of-the-box features! I mostly don't have to develop anything.

— Simon Beginn, LANCOM Systems

Real Speed
Troubleshooting in 30 Seconds

From 2-3 minutes to 30 seconds—instant visibility into any node issue.

— Matthew Artist, Nodecraft

20% Downtime Reduction

20% less downtime and 40% budget optimization from out-of-the-box monitoring.

— Simon Beginn, LANCOM Systems

Pay per Node. Unlimited Everything Else.

One price per node. Unlimited metrics, logs, users, and retention. No per-GB surprises.

Free tier—forever
No metric limits or caps
Retention you control
Cancel anytime
> See pricing plans

What's Your Monitoring Really Costing You?

Most teams overpay by 40-60%. Let's find out why.

Expose hidden metric charges
Calculate tool consolidation
Customers report 30-67% savings
Results in under 60 seconds
> See what you're really paying

Your Infrastructure Is Unique. Let's Talk.

Because monitoring 10 nodes is different from monitoring 10,000.

On-prem & air-gapped deployment
Volume pricing & agreements
Architecture review for your scale
Compliance & security support
> Start a conversation

Monitoring That Sells Itself

Deploy in minutes. Impress clients in hours. Earn recurring revenue for years.

30-second live demos close deals
Zero config = zero support burden
Competitive margins & deal protection
Response in 48 hours
> Apply to partner

Per-Second Metrics at Homelab Prices

Same engine, same dashboards, same ML. Just priced for tinkerers.

Community: Free forever · 5 nodes · non-commercial
Homelab: $90/yr · unlimited nodes · fair usage
> Get the Homelab Plan

$1,000 Per Referral. Unlimited Referrals.

Your colleagues get 10% off. You get 10% commission. Everyone wins.

10% of subscriptions, up to $1,000 each
Track earnings inside Netdata Cloud
PayPal/Venmo payouts in 3-4 weeks
No caps, no complexity
> Get your referral link
Cost Proof
40% Budget Optimization

"Netdata's significant positive impact" — LANCOM Systems

Calculate Your Savings

Compare vs Datadog, Grafana, Dynatrace

Savings Proof
46% Cost Reduction

"Cut costs by 46%, staff by 67%" — Codyas

30% Cloud Bill Savings

"Reduced cloud bill by 30%" — Falkland Islands Gov

Enterprise Proof
"Better Than Combined Alternatives"

"Better observability with Netdata than combining other tools." — TMB Barcelona

Real Engineers, <24h Response

DPA, SLAs, on-prem, volume pricing

Why Partners Win
Demo Live Infrastructure

One command, 30 seconds, real data—no sandbox needed

Zero Tickets, High Margins

Auto-config + per-node pricing = predictable profit

Homelab Ready
Free Video Course

8-episode Netdata tutorial by LearnLinux.tv

76k+ GitHub Stars

3rd most starred monitoring project

Worth Recommending
Product That Delivers

Customers report 40-67% cost cuts, 99% downtime reduction

Zero Risk to Your Rep

Free tier lets them try before they buy

AI Support Assistant, Available 24/7

Nedi has access to all official documentation, source code, and resources. Ask any question about Netdata—responds in your language.

Deployment & configuration
Troubleshooting & sizing
Alerts & notifications
Evidence-based answers
> Ask Nedi now

Never Fight Fires Alone

Docs, community, and expert help—pick your path to resolution.

Learn.netdata.cloud docs
Discord, Forums, GitHub
Premium support available
> Get answers now

60 Seconds to First Dashboard

One command to install. Zero config. 850+ integrations documented.

Linux, Windows, K8s, Docker
Auto-discovers your stack
> Read our documentation

76,000+ Engineers Strong

615+ contributors. 1.5M daily downloads. One mission: simplify observability.

Per-Second. 90% Cheaper. Data Stays Home.

Side-by-side comparisons: costs, real-time granularity, and data sovereignty for every major tool.

See why teams switch from Datadog, Prometheus, Grafana, and more.

> Browse all comparisons
Edge-Native Observability, Born Open Source
Per-second visibility, ML on every metric, and data that never leaves your infrastructure.
Founded in 2016
615+ contributors worldwide
Remote-first, engineering-driven
Open source first
> Read our story
Promises We Publish—and Prove
12 principles backed by open code, independent validation, and measurable outcomes.
Open source, peer-reviewed
Zero config, instant value
Data sovereignty by design
Aligned pricing, no surprises
> See all 12 principles
Edge-Native, AI-Ready, 100% Open
76k+ stars. Full ML, AI, and automation—GPLv3+, not premium add-ons.
76,000+ GitHub stars
GPLv3+ licensed forever
ML on every metric, included
Zero vendor lock-in
> Explore our open source
Build Real-Time Observability for the World
Remote-first team shipping per-second monitoring with ML on every metric.
Remote-first, fully distributed
Open source (76k+ stars)
Challenging technical problems
Your code on millions of systems
> See open roles
Meet the Team Behind Netdata
Conferences, meetups, and tradeshows where you can see Netdata in action and talk to the engineers who build it.
Live demos and deep dives
Book 1-on-1 meetings
Talks and panel sessions
Event recaps and photos
> See all events
Talk to a Netdata Human in <24 Hours
Sales, partnerships, press, or professional services—real engineers, fast answers.
Discuss your observability needs
Pricing and volume discounts
Partnership opportunities
Media and press inquiries
> Book a conversation
Your Data. Your Rules.
On-prem data, cloud control plane, transparent terms.
Trust & Scale
76,000+ GitHub Stars

One of the most popular open-source monitoring projects

SOC 2 Type 2 Certified

Enterprise-grade security and compliance

Data Sovereignty

Your metrics stay on your infrastructure

Validated
University of Amsterdam

"Most energy-efficient monitoring solution" — ICSOC 2023, peer-reviewed

ADASTEC (Autonomous Driving)

"Doesn't miss alerts—mission-critical trust for safety software"

Community Stats
615+ Contributors

Global community improving monitoring for everyone

1.5M+ Downloads/Day

Trusted by teams worldwide

GPLv3+ Licensed

Free forever, fully open source agent

Why Join?
Remote-First

Work from anywhere, async-friendly culture

Impact at Scale

Your work helps millions of systems

$ guides / memcached / memcached-connection-refused ▌

Operations Guides

Memcached connection refused: telling a dead process from a hung or full one

“Connection refused” from a memcached client is commonly misdiagnosed. Operators run a TCP port check, see that the port is open, and act on that single data point. A port test tells you whether the kernel accepts a TCP SYN on 11211, not whether memcached is processing commands.

Three distinct failure modes all surface to clients as “cannot reach memcached”:

  1. Process dead: crashed, OOM-killed, or never owned the port. The kernel refuses the connection.
  2. Process hung: alive but unresponsive. The kernel accepts the connection because the listen socket is open, but commands never return.
  3. Connection limit reached: healthy but saturated. New connections are rejected, queued indefinitely, or accepted but never serviced.

Each requires a different response. Restarting a hung process without understanding why it hung will reproduce the hang. Raising the connection limit on a dead process does nothing.

The diagnostic move is to send an actual command (version or stats) and require a response within a few seconds. This separates all three modes before you touch dmesg, ss, or stats settings. Require three consecutive failures over 30-60 seconds before escalating: transient blips during deploys and reconnection storms are real.

What this means

The kernel returns ECONNREFUSED (errno 111) when nothing is listening on the destination IP:port. A full listen backlog on Linux does not produce ECONNREFUSED by default (tcp_abort_on_overflow defaults to false); the kernel drops the SYN silently and the client sees a timeout. For memcached, ECONNREFUSED almost always means the daemon is not bound to the address your client is using, or the process has exited.

A TCP connection that succeeds only tells you the listen socket accepted your SYN. It does not confirm that a worker thread read your command, parsed it, or wrote a reply. A memcached process that is deadlocked, stopped, swap-thrashing, or stuck in a long-running internal operation can still have an open listen socket fed by the kernel. From the client’s perspective, this looks like a connection that hangs or times out rather than a clean refuse.

The third mode is subtler. When curr_connections reaches max_connections, memcached sets accepting_conns = 0 and stops calling accept(). New SYNs queue in the kernel backlog and eventually time out from the client’s perspective. With maxconns_fast (the default since 1.5.0), over-limit connections that do get accepted are answered with ERROR Too many open connections and immediately closed, and rejected_connections increments — the TCP connect itself succeeds, so this never surfaces as ECONNREFUSED.

flowchart TD
    A["Client reports
connection refused"] --> B{"TCP connect to
IP:port succeeds?"} B -- "refused (ECONNREFUSED)" --> C["Process dead/crashed/
OOM-killed/port conflict"] B -- "connects" --> D{"version command
responds in 2s?"} D -- "no response" --> E["Process hung:
silent degradation"] D -- "VERSION x.y.z" --> F{"accepting_conns = 0
or new conns refused?"} F -- "yes" --> G["At connection limit:
curr_connections near max"] F -- "no" --> H["Daemon healthy:
look upstream
(firewall, IP, LB)"]

Common causes

CauseWhat it looks likeFirst thing to check
Process dead or crashedps shows no PID, or PID is recent (uptime reset); TCP refusedsystemctl status memcached, journalctl -u memcached, dmesg -T | grep -Ei 'killed process|oom'
OOM-killedProcess gone, kernel log shows oom-killer invocationdmesg -T | grep -i oom, /proc/<pid>/status before the next kill
Port conflict or wrong bind addressProcess running, port check from localhost succeeds but remote clients failss -tlnp | grep 11211, stats settings | grep inter
Process hungps shows the process, TCP connects, but version/stats times outps -o pid,stat,etime,cmd -p <pid> for state D/T, check VmSwap
Connection limit reachedversion responds on existing connections but new ones queue or refuse; accepting_conns = 0stats | grep -E 'curr_connections|max_connections|accepting_conns|rejected_connections|listen_disabled_num'
Firewall or network partitionPort check fails intermittently or only from specific source IPsss -tn state established '( sport = :11211 )', firewall logs

Quick checks

All read-only. Run as a first pass.

# Send a real command and require a response. This is the single most important check.
echo "version" | nc -w 2 localhost 11211
# Expected: VERSION x.y.z
# Empty or timeout: process is dead, hung, or unreachable.

# Confirm the process is running and capture its state.
pgrep -a memcached
ps -o pid,ppid,stat,etime,rss,cmd -p "$(pgrep -x memcached)"
# State D (uninterruptible sleep) or T (stopped) indicates a hang, not a crash.

# Confirm the listening socket: which interface, which port, which PID owns it.
ss -tlnp | grep 11211

# Check whether the server is at its connection limit.
echo "stats" | nc -w 2 localhost 11211 | grep -E 'STAT (curr_connections|max_connections|accepting_conns|rejected_connections|listen_disabled_num|time_in_listen_disabled_us)'

# Check for OOM kills.
dmesg -T | grep -Ei 'killed process|oom-killer|out of memory' | tail -20

# Check for unexpected restarts.
echo "stats" | nc -w 2 localhost 11211 | grep -E 'STAT (uptime|pid|time)'

# Check whether the process has been swapped (catastrophic for an in-memory cache).
grep -E 'Vm(RSS|Swap)' /proc/"$(pgrep -x memcached)"/status

# Check the configured bind address, threading, and maxconns.
echo "stats settings" | nc -w 2 localhost 11211 | grep -E 'STAT (inter|udpport|num_threads|maxconns)'

How to diagnose it

Place the failure into exactly one of three buckets before changing anything.

Step 1: send a command, not a SYN. From the memcached host, run echo "version" | nc -w 2 localhost 11211. Three outcomes:

  • TCP connect refused immediately: go to step 2.
  • TCP connects, no response within 2 seconds: go to step 3 (likely hung).
  • VERSION x.y.z returns cleanly: the daemon is alive on localhost. Go to step 4.

Step 2: confirm the process is dead and find the cause. Run pgrep -a memcached. If nothing returns, the process is gone. Check:

  • systemctl status memcached (or your supervisor) for exit status and recent restart attempts.
  • journalctl -u memcached --since "30 min ago" for stderr output.
  • dmesg -T | grep -Ei 'killed process|oom'. The Linux OOM killer log line names the process, PID, and oom_score.

If the process is running but the port is still refused, you have a port conflict or wrong bind address. Use ss -tlnp | grep 11211 to confirm which PID owns the port, and stats settings | grep inter to check the configured bind address. A memcached bound to 127.0.0.1 will refuse connections from an external interface even when perfectly healthy.

Step 3: confirm the process is hung, not just slow. A single slow version response is not proof. Require three consecutive failures spaced over 30-60 seconds, with uptime stable across checks. A fresh start (low uptime) that fails to respond is a startup failure, not a hang.

While the checks run:

  • ps -o pid,stat,etime -p <pid>: state D (uninterruptible sleep, usually I/O) or T (stopped) confirms a kernel-level stall. State R or S with no response suggests userspace deadlock.
  • grep VmSwap /proc/<pid>/status: any nonzero value means the process is partially on disk. This is a production incident in its own right.
  • cat /proc/loadavg: severe memory pressure shows elevated load with no obvious CPU consumer, often the OOM killer winding up.

If you can still get a stats response from an existing connection (some monitoring tools hold one open), check cmd_get and cmd_set rates. Near-zero throughput with stable uptime and accepting_conns = 1 is the signature of silent process degradation.

Step 4: if localhost is healthy, check the connection limit and network path. Run stats | grep -E 'accepting_conns|curr_connections|max_connections|rejected_connections|listen_disabled_num'. Interpret:

  • accepting_conns = 0 with curr_connections near max_connections: the server is saturated. See the connection-limit fix below.
  • accepting_conns = 1 and rejected_connections is zero: memcached is fine. The refuse is happening upstream: firewall, network partition, wrong destination IP, or a load balancer with a stale health check.

Then test from the client host: echo "version" | nc -w 2 <memcached-ip> 11211. If that fails but the localhost check passes, run ss -tn state established '( sport = :11211 )' on the memcached host to see who is connected, and check iptables -L -n and any cloud security groups.

Metrics and signals to monitor

SignalWhy it mattersWarning sign
version/stats probeThe only definitive liveness check; a SYN is not enough3 consecutive failures over 30-60s with stable uptime
uptimeResets on restart, meaning total cache lossDiscontinuity with no planned maintenance
accepting_connsReal-time boolean for “at connection limit”Flips to 0
curr_connections / max_connectionsSaturation ratioSustained above 0.8; cliff-edge at 1.0
rejected_connectionsCounter of connections refused under maxconns_fastAny increment in production
listen_disabled_numCount of listener-disable transitionsAny non-zero value
cmd_get, cmd_set ratesThroughput; near-zero with stable uptime indicates a hangDrop to under 10% of baseline
VmSwap for the processSwapped cache memory means disk-speed accessAny nonzero value
Process state from psDistinguish kernel stall (D/T) from userspace deadlock (R/S)State D or T
OOM killer logExplains sudden process disappearancedmesg shows Killed process <pid> (memcached)

Fixes

Treat each branch separately. Do not restart memcached reflexively: every restart is total cache loss and a thundering herd on the backend.

Process dead or crashed

Recover via your supervisor (systemctl start memcached). Before you do, capture evidence: the OOM killer line, the supervisor’s exit status, and any stderr. A crash with no log usually means OOM kill or an external signal.

If the OOM killer is the cause, the fix is on the host:

  • Check /proc/<pid>/status for VmRSS against the host’s free memory. Memcached RSS should be roughly limit_maxbytes plus overhead for the hash table and connection buffers.
  • Verify the cgroup memory limit if running in a container. The cgroup OOM killer fires on cgroup limits independently of host memory.
  • Consider -k (mlockall) to prevent swap and turn memory pressure into an earlier, louder allocation failure. Reduce -m or move other processes off the host.
  • Confirm ulimit -n for the memcached process is at least as high as max_connections. The OS file descriptor limit silently caps the daemon below its configured connection limit.

Process hung (silent degradation)

A hung process requires a restart to recover service, but the diagnostic value of the hung state is high. Capture what you can before killing it:

  • A few stack traces via gdb -p <pid> -batch -ex 'thread apply all bt' — the process stays stopped until the batch detaches. Worker threads stuck in the same function point to a deadlock. Threads in __GI___libc_malloc or madvise point to allocator or memory pressure.
  • /proc/<pid>/status for VmSwap and VmRSS.
  • /proc/<pid>/wchan per thread for kernel wait reasons.

Then restart via your supervisor. Do not skip evidence collection: a hang that reproduces is much easier to root-cause with one captured trace than with three clean restarts.

If VmSwap is nonzero, the underlying problem is host memory pressure, not memcached. Adding -k converts silent swap thrash into an earlier allocation failure and prevents the disk-latency regime entirely.

Connection limit reached

Raising -c requires a restart and is the wrong first move if the cause is a connection leak. Before touching the limit:

  • ss -tnp | grep :11211 | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -rn: which clients hold the most connections?
  • Sample total_connections twice with a known interval. If curr_connections is pegged at max but the total_connections rate is very high, clients are churning connections (no pooling). If curr_connections is pegged and the total_connections rate is low, connections are leaking: held open and never closed.
  • Check client-side connection pool settings. Persistent connections are the standard fix for churn.

If the workload legitimately needs more concurrent connections, raise -c on next restart and raise ulimit -n to match. Memcached will not exceed the OS limit. Keep -o maxconns_fast enabled (the default since 1.5.0) so over-limit clients get a fast refuse instead of a multi-second queue-and-timeout, but expect rejected_connections to start incrementing.

Wrong bind address or port conflict

If ss -tlnp | grep 11211 shows a different PID owning the port, identify and stop that process before restarting memcached. If memcached is bound to 127.0.0.1 and clients use the external IP, change the -l flag to bind the correct interface and restart. Always pair a bind-address change with firewall rules: exposing memcached to untrusted networks without SASL is a serious security issue. UDP has been disabled by default since 1.5.6; keep it that way.

Prevention

  • Command-probe alerting, not port-check alerting. Alert on version probe failure sustained for 3 checks over 30-60 seconds, with uptime previously stable. A bare TCP port check is not a liveness signal.
  • Connection-exhaustion composite alert. Alert on accepting_conns = 0 sustained for 5 minutes with curr_connections / max_connections > 0.98. Brief reconnection storms after deploys should not page.
  • Swap alerting. Alert on any nonzero VmSwap for the memcached process. Treat even single-digit megabytes as an incident.
  • Flush alerting. Alert on any cmd_flush increment in production.
  • Restart alerting. Alert on uptime discontinuities.
  • Leading indicators. Track listen_disabled_num. Any non-zero value means the server has hit its connection limit at least once.
  • File descriptor headroom. Set ulimit -n to at least max_connections + headroom, and verify it in the supervisor unit.
  • Lock memory. Run with -k (mlockall) on hosts where you want swap pressure to surface as an allocation failure rather than silent latency.
  • Know your version. Slab reassign, slab_automove, and the segmented LRU turned on by default in 1.5.0; UDP has been disabled by default since 1.5.6. The stats settings output tells you which features are active.

How Netdata helps

  • The memcached collector issues real command probes (stats, version) per second rather than bare TCP checks. A failed command response with a live port surfaces as an anomaly instead of a false green.
  • Per-second curr_connections, accepting_conns, rejected_connections, and listen_disabled_num let you correlate a connection-limit event with the exact moment accepting_conns flips to 0.
  • ML anomaly detection on cmd_get and cmd_set rates catches the silent-degradation signature: throughput collapsing while uptime stays stable and the port stays open.
  • Host-level collectors (OOM killer events, per-process RSS and swap, cgroup memory limits) sit alongside the memcached metrics, so cause and effect are visible on the same timeline.
  • Composite alerting on sustained accepting_conns = 0 plus curr_connections / max_connections > 0.98 avoids pages from deploy-time storms while still paging on real saturation.