The topology primary always sends a digest of its subtree contents on each update. If the node has a different digest than the primary, it knows it's not synchronized. The servers will pull the entire subtree from the primary if they detect that they are not synchronized. A server can detect it is not synchronized with the primary under the following conditions:

  • At the end of its periodic polling interval, if a server's subtree digest differs from that of its primary, then it knows it's not synchronized.
  • If one or more servers have been added to or removed from the topology, the servers will not synchronize.

The primary of the topology is selected by prioritizing servers by minimum supported product version, most available, newest server version, earliest start time, and startup UUID (a smaller UUID is preferred).

After determining a primary, the topology data is reviewed from all available servers (every five seconds by default) to determine if any new information makes a server better suited to being the primary. If a new server can be the primary, it will communicate that to the other servers, if no other server has advertised that it should be the primary. This ensures that all servers accept the same primary at approximately the same time (within a few milliseconds of each other). If there is no better primary, the initial primary maintains the role.

After the best primary has been selected for the given interval, the following conditions are confirmed:

  • A majority of servers is reachable from that primary. (The primary server itself is considered while determining this majority.)
  • There is only a single primary in the entire topology.

If either of these conditions is not met, the topology is without a primary and the peer polling frequency is reduced to 100 milliseconds to find a new primary as quickly as possible. If there is no primary in the topology for more than one minute, a mirrored-subtree-manager-no-master-found alarm is raised. If one of the servers in the topology is forced as primary with the force-as-master-for-mirrored-data option in the Global Configuration configuration object, a mirrored-subtree-manager-forced-as-master-warning warning alarm is raised. If multiple servers have been forced as primaries, then a mirrored-subtree-manager-forced-as-master-error critical alarm will be raised.