PegaProx High Availability
Available from PegaProx 1.3
High availability for PegaProx itself is part of PegaProx 1.3. It is not in 1.2. Automatic failover comes as a beta in 1.4.0, see below.
PegaProx can run as a group of up to four instances, so that losing the machine PegaProx runs on does not leave you without a management plane. This page explains the idea. Setting up a group and failover and day-to-day operation have their own pages.
This is about PegaProx itself. Keeping your guests running when a Proxmox node fails is a different feature, see High Availability (guests).
Roles in a group
| Role | What it does |
|---|---|
| Leader | Holds the configuration the others copy, connects to all clusters, and is the only instance that runs automation: HA monitoring, load balancing, schedules, snapshot policies, scheduled updates and alerts. Every change made anywhere in the group is carried out here. |
| Active member | Serves users like the leader: consoles, shells and SPICE open there, and the live data comes straight from the clusters. Changes made on an active member are handed to the leader, which carries them out under the same account and syncs them back right after. |
| Standby | Copies the leader's configuration and waits to take over. With the live view on it shows live data from the clusters, read only unless forwarding is on. |
| Standalone | A single instance, not paired with anyone. This is how every installation starts. |
A group holds at most four instances, the leader included, and at most three of them active, the leader included. Every other member stays a standby.
What the group shares
The leader holds the shared configuration: users, roles and tenants, clusters and their credentials, settings, schedules, policies and the rest of what you configure. Members pull it on a fixed interval (30 seconds by default) and whenever the leader tells them it changed. Each member keeps what belongs to the machine itself: its own address, port and certificate, its sync interval, and its live view and forwarding switches.
Members talk to each other over HTTPS on the main PegaProx port, with calls signed by a key of their own. A member that was removed from the group is refused by every other member.
A sync never silently throws away what a member held. If it replaces rows the member had and the leader did not, the replaced rows are kept as an encrypted copy on that member, which an admin can download or dismiss. See Changes that were not carried over.
Signing in on a member
Users sign in on any member with their usual account. A change handed from a standby or active member to the leader is checked by the leader against its own users and permissions, and the audit log names the member it came from. LDAP and OIDC sign-ins on a member go by the account synced from the leader and write nothing on the member.
What runs where
- Automation runs on the leader only. A standby or active member never acts on its own: no HA restarts, no balancing, no schedules, no alerts.
- Consoles and shells open on the leader and on active members. On a plain standby they are offered on the active instance instead.
- Changes made on an active member, or on a standby with forwarding on, are carried out by the leader. While the leader does not answer, changes are paused and say so; live data and consoles keep working.
- Schedules fire by the wall time of the group's time zone on whichever member leads, so a failover to a member in another time zone does not shift them. See Time zone of the schedules.
Failover: manual, or automatic as a beta
Every group fails over by hand until an administrator switches it: when the leader is gone, an administrator promotes another member to leader. The old leader steps down as soon as it sees the new one, also if it comes back later. See When the leader is gone. Manual mode is the default of every group, new or updated.
Automatic failover is a beta
Since 1.4.0 a group can also fail over automatically: the members elect a new leader by majority when the leader fails. It is new in 1.4.0. Try it in your setup before you rely on it; you can switch back to manual failover at any time. On 1.3.0 the HA page offers neither automatic failover nor a witness, and the API refuses both with "Automatic failover is not available in this release yet".
Automatic failover needs at least three votes: three data members, or two and a witness, a third vote that holds no data. An administrator switches it on at the Automatic failover card on the leader's HA page, once the checklist there has no red item left. It brings Make leader, which hands the lead to another member on purpose, and Force leader, the way out of a group that lost its majority for good. See Automatic failover (beta) for switching it on and the witness, and Automatic failover for what happens when the leader fails.
Who may do what
Every action on the High Availability page (pairing, promoting, removing members, the live view and forwarding switches, the time zone, the switch to automatic failover, Make leader, Force leader and the witness) is for administrators only. An administrator confined to a tenant cannot change the group.