When updating, the primary sends a digest of its subtree contents. If the node's digest differs from the primary's, the server node knows it is not synchronized. The servers pull the entire subtree from the primary if they detect that they are not synchronized.

A server detects it is not synchronized with the primary under the following conditions:

  • The server's subtree digest differs from the primary's digest at the end of its periodic polling interval.
  • One or more servers have been added to or removed from the topology.

The primary of the topology is selected by prioritizing servers based on:

  • Minimum supported product version
  • Availability
  • Server version
  • Earliest start time
  • Startup UUID (smaller 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 identifies a better server primary. If a new server can be the primary and no other servers have indicated that they should be the primary, it will communicate its eligibility to the other servers. 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 object, a mirrored-subtree-manager-forced-as-master-warning warning alarm is raised. If multiple servers have been forced as primaries, then a multiple-servers-forced-as-masters alarm is raised.