Skip to content
You're viewing documentation for v2026.11.10-beta. It may be out of date.Go to latest
TimescaleDB Enterprise
Esc
↑↓navigate↵open⌘Jpreview
On this page

HAProxy or PgBouncer failure

Recover a stopped HAProxy or PgBouncer on a node of an HA service, and check that the VIP and the pooled and direct ports serve again.

Each node of an HA service runs HAProxy (port 5000 pooled through PgBouncer, port 6000 direct to the primary) and PgBouncer.

Symptoms

  • PgBouncer stopped on the primary: connections on port 5000 fail with connection refused. Port 6000 continues to work.
  • HAProxy stopped on the VIP holder: another node takes the VIP in about 12 s. Open connections close.
  • On the service Overview, Database service health shows PgBouncer needs attention or HAProxy needs attention. The service status stays running.
Service topology with HAProxy shown as unhealthy on one nodeService topology with HAProxy shown as unhealthy on one node

Recovery

Find the unhealthy unit

In the topology, find the node and the unit (pgbouncer or haproxy) that is unhealthy. If the console is not available, run systemctl status pgbouncer haproxy on each PostgreSQL node.

Read the log

Read the log of the unit. For PgBouncer, use Logs & Diagnostics (source PgBouncer). For HAProxy, run this on the node:

sudo journalctl -u haproxy -n 100

Start the unit

Start the unit:

sudo systemctl start <unit>

Check the unit

Confirm that the topology shows the unit as healthy, and that a client connection works again. If the unit does not start, or stops again, contact support.

Check the VIP

On a service with a VIP, run this on each PostgreSQL node:

ip -4 addr show | grep <vip>
  • Good: the VIP is on one node.
  • Bad: the VIP is on no node or on more than one. Contact support.

The VIP does not move back when HAProxy starts again.

Prevention

  • Keep the shipped unit settings: they restart a unit that fails. A unit that you stop with systemctl stop stays stopped.
  • Connect clients through the VIP, and configure them to reconnect after an error.