The Global Synchronization process is a series of various stages to consolidate items across the various data sources.
The various Stages are:
Access Rights, Aliases, Cached Items, Combinations, Device Life Cycle State, Domain Groups, Dynamic Groups, Item Members, Item Types,
Items (which includes Address, Component, Device, Domain, Group, Interface, Product, Tenant), Property Types, Relation Types, Subnets,
and Tenant Groups.
Each of these stages will look at various entities that needs to be consolidated.
Note: The order of stages for a device is the following, because each builds off the previous: Device, Interface, Address, Component
Here is a description of some of the algorithms that determine how we consolidate across the data sources. All synchronization is done by IP Domain, so if 2 devices appear to be the same, check if they are in different IP Domain.
1. We compare the primary IP address (main address synced with the device in dst_device) to all other device primary IP address
2. We compare the primary IP address to all synced secondary IP addresses from other devices in other data sources (in 3.2 Oct and newer).
Note: NFA doesn't sync a secondary IP address. DA doesn't sync loopback addresses. DA only synces IP addresses of polled interfaces. Spectrum syncs all interfaces associated for the device.
3. For loopback addresses that are synced as primary IP address, we do an extra couple queries to consolidate them since the DA doesn't sync loopback addresses but Spectrum does.
Note: if Spectrum is not a data source, and if NFA syncs a loopback address as it's primary IP address, we will not be able to consolidate the 2 devices, because there will be no IPs in common.
Note: to avoid device consolidation issues using loopback address, try and use non-loopback address as the primary IP address when discovering a device in the various data sources.
Some notes about the comparison:
1. In 3.5 (and 3.1/3.2 monthly kit), we will no longer consolidate ADA devices to any others based on secondary address.
2. In 3.5 (and 3.1/3.2 monthly kit), we will no longer consolidate devices to any others devices in the same data source based on secondary address, IFF they come from that data source ONLY.
3. We currently can't stop consolidating based on primary from the same data source, because we don't know which to chose if the device comes from another data source also. So any device with the same primary IP address will be consolidated together.
4. In 3.2 Oct, 3.5 and newer, the bold text above comes into play. Before these changes, it would find other devices from the same data source based on primary->secondary.
1. We compare interfaces across the data sources on ifIndex and parent device itemid (this is why we must consolidate devices first).
Note: if there are more than 1 interface from the same device with the same ifIndex, we will consolidate them together. Possibly due to multiple vendor certs discoverying multiple interfaces and give them same ifIndex.
1. We compare the IP address with the same parent interface itemid (this is why we must consolidate the interfaces first).