Important
High availability is available in the Enterprise edition.
Two servers run one installation together. The primary serves everything; the standby keeps a live, streaming copy of the primary’s database and starts its API, collector and web interface only when it takes over. A virtual address always points at the primary, so users, remote collectors, agents and phones never need to know which server is which.
virtual address 192.0.2.10
/ \
server A (primary) server B (standby)
database ── replication ──▶ database (read only)
API, collector, web API, collector, web stopped
The standby needs no license of its own: it becomes a copy of the primary, license included, and the pair checks in as one installation.
Before you start
- Two servers in the same network, with the same Monitoring version installed. Nothing else configured on the second one.
- A free virtual address in that network.
- Two or more witnesses: hosts on your users’ side of the network that answer on a TCP port - a router, a DNS server, the reverse proxy. A server that reaches none of them knows it is the one cut off and does not take the address.
- The two servers reach each other on TCP 5544 (database replication) and VRRP. Servers installed from the ISO already allow both from private networks.
netmon-ha-agent.servicerunning on both servers (the installer enables it). The web interface only records what an admin asks for; this agent carries it out on the host.
Set up the pair
- On the first server, open Settings → High availability → Make this server the primary. Enter the second server’s address, the virtual address and its network prefix, and the witnesses (the page offers the default gateway and DNS servers that answer). Confirm. The agent installs keepalived, opens replication for the standby and adds the virtual address. The web interface restarts once - about a minute.
- Still on the primary, Create a join code. The code is shown once and works once, for an hour, only from the standby’s address.
- On the second server, open Settings → High availability → Join an existing primary. Enter the primary’s own address (not the virtual address or a proxy in front of it) and the code. The second server checks that both run the same version, takes over the primary’s settings and secrets, copies the database and becomes the standby. Everything that was on it is replaced, and its web interface stops - from now on use the virtual address.
- Point the reverse proxy or your DNS name, the users, remote collectors and agents at the virtual address.
In tests, setting up the primary took under a minute and joining about 35 seconds from the click to a streaming standby.
What happens when the primary fails
The virtual address moves to the standby within seconds. The standby refuses to take over when it reaches no witness, or while the old primary’s database still answers - two writable databases would split the data. Otherwise it promotes its database and starts the API, collector and web interface.
- Sessions stay valid; polling resumes within a minute.
- Traps and syslog sent to the virtual address arrive at the new primary.
- Replication is asynchronous: the last seconds of poll results that had not reached the standby can be lost. Configuration changes made earlier are not.
In tests on two real hosts, a hard power-off of the primary left the service unanswered for roughly 20 to 40 seconds.
Planned maintenance: switch roles
Switch roles on the High availability page: the primary stops serving, waits until the standby has applied every change, hands over the address and rebuilds itself as the new primary’s standby. About a minute without the web interface, nothing lost.
Bring a former primary back
A failed primary that comes back starts on its own, outdated copy of the database. It does not get the address back and stops its API and collector by itself. The new primary reports it as a former primary with old data.
- Rebuild it as the standby on the High availability page makes it the new primary’s standby again (in tests, streaming 24 seconds after the click).
- Or tick Rebuild a former primary automatically.
Watching the pair
- Settings → High availability shows both servers, the replication, the virtual address, keepalived and the newest 15 events.
- The Dashboard shows a High availability panel on a pair: the replication state and how far behind the standby is, drawn live, the virtual address, keepalived, witnesses, the agent and the last failover.
- Reports → Statistics shows the standby’s state and how much it has not applied yet.
Two alerts cover the pair, sent to every organization’s channels:
| Alert | When |
|---|---|
| HA replication (critical) | The standby is not connected, still catching up or more than 256 MB behind for two checks in a row - or the primary runs without any standby. Being in sync again resolves it. |
| HA event | A server became the primary; keepalived not running on the primary; the primary reaches none of its witnesses; the primary serves without the virtual address; the agent on the primary stopped reporting; a former primary is back with old data; a refused join request. |
Notes
- Database backups run on the primary. Configure them before you set up the pair; both servers then carry the same settings.
- While the standby is away, the primary keeps the changes it has not received (up to 10 GB); past that, the standby is rebuilt from a fresh copy. If you retire the standby for good, contact Nocward support so the primary stops keeping changes for it.
- Software updates and resource sizing keep the pair’s settings.