Skip to content

Setting up a WHM DNS cluster — peers, trust, and the order that avoids split-zone state

A WHM DNS cluster ties two or three nameservers together so zone changes propagate. The setup order matters; cluster trust set up wrong leaves zones partially synced.

A new pair of nameservers needs to participate in your hosting environment’s DNS. The WHM DNS Cluster interface advertises this as a few clicks — point WHM at the peer’s hostname, paste an API token, and zones sync. The catch is that “syncs” hides a precise sequence of trust handshakes; do them out of order and you end up with one server thinking the other is a peer while the other thinks the first is a stranger. Zones edited on the wrong side don’t propagate. The fix is the right order, end to end.

What’s happening

A WHM DNS cluster is a mesh of trust relationships, not a star topology. Every server in the cluster needs to know every other server, with an API token granting dns-cluster ACL. When you edit a zone on any server, it’s pushed to every peer that trusts it; conversely, that server pulls zones modified on peers. The cluster does not have a master; everyone is equal, and conflicts are resolved by serial number (the SOA serial). Trust is bidirectional: A trusts B does not mean B trusts A. Both directions must be configured.

How to verify

Audit the current cluster state from each candidate server:

whmapi1 list_dns_cluster_peers
whmapi1 get_dns_cluster_status
cat /var/cpanel/cluster/root/config/*
tail -f /usr/local/cpanel/logs/error_log | grep -i cluster
dig @ns2.example.com SOA example.com

The peer list should be identical on every cluster member after setup. The cluster status shows pending sync operations; if it’s non-empty for hours, the cluster has a connectivity or trust problem.

The fix

For a two-node cluster (ns1 and ns2), the setup order:

  1. On ns1, create the API token for cluster use: whmapi1 api_token_create token_name=dns-cluster-ns2-2026 acl-1=dns-cluster. Capture the returned token; it’s only shown once.
  2. On ns2, register ns1 as a peer: WHM > Configure Cluster, or whmapi1 add_dns_cluster_peer user=root host=ns1.example.com token=<the token from step 1>. ns2 now trusts ns1 — meaning ns2 will accept zone pushes from ns1.
  3. Repeat in reverse: on ns2, create a cluster token; on ns1, register ns2 as a peer. Now ns1 trusts ns2 as well. Trust is bidirectional.
  4. For each cluster member, set the role per peer. The default role is Standalone (no sync). Set to Synchronize Changes for active two-way sync, or Write-Only if you want one-way push (rare; useful when a peer is a hidden secondary).
  5. Validate by editing a test zone on either node: whmapi1 add_zone domain=test-cluster-2026-05.example.com. Within seconds, the same zone should appear on every other cluster member. whmapi1 get_zone_info domain=test-cluster-2026-05.example.com on each peer confirms.
  6. Add the third node before scaling further. Three nodes is the common production shape; it gives you survivability when one is down for maintenance.

For shops running their own DNS infrastructure, Stack Harbor’s deployment management practice sets up multi-region clusters with the trust handshakes scripted so adding a fourth or fifth node is a one-command operation.