MID Server selection sequence for Discovery schedules
Summarize
Summary of MID Server selection sequence for Discovery schedules
This guide explains how the Discovery application in ServiceNow selects MID Servers during Discovery schedules. It covers the selection logic for both auto-selection and cluster-based MID Server selection methods, as well as details on how IP addresses are distributed during the port scan (Shazzam) phase.
Show less
Auto-Selection of MID Servers
- When "Auto-Select MID Server" is chosen on the Discovery Schedule form, Discovery looks for MID Servers with a matching IP range.
- If none are found, it searches for MID Servers assigned to the ALL application with an appropriate IP range.
- If multiple MID Servers qualify, the first with status Up is chosen; if multiple are up, one is picked randomly.
- If no MID Servers are Up, the default MID Server for Discovery or ALL applications (if specified and Up) is used.
- If no default MID Server is specified or available, Discovery considers MID Servers with status Paused or Upgrading, although these do not process commands until they return to Up.
- Note: Auto-select does not support IPv6 addresses.
MID Server Cluster Selection
When "Specific MID Cluster" is selected, the selection depends on the cluster type:
- Load balancing cluster: Discovery picks the first MID Server found with status Up. If multiple are up, it randomly selects one. If none are available, it looks for MID Servers with status Paused or Upgrading.
- Failover cluster: Discovery chooses the MID Server with the lowest Order value that is Up. If none are up, it selects from those Paused or Upgrading by lowest Order value.
Note: When selecting from clusters, Discovery ignores any default MID Server settings.
Port Scan (Shazzam) Phase
- During this phase, Discovery collects all target IP addresses and evenly distributes them across qualified MID Servers for port scanning.
- The number of IP addresses each Shazzam probe scans is controlled by the Shazzam batch size configured in the Discovery schedule.
- Example: For 16,000 IP addresses and 3 MID Servers, two servers might scan 5,000 IPs each, and the third scans 6,000 IPs using two Shazzam probes.
- Shazzam supports IP lists up to 5,000 addresses, including both IPv4 and IPv6.
- IPv6 usage notes:
- If an IP list has more than 5,000 IPv6 addresses, Discovery will cancel the schedule.
- Only IP lists (not IPv6 address ranges or networks) are supported for IPv6. IPv6 ranges and networks are ignored.
The Discovery application follows this sequence to find a MID Server.
MID Server auto-selection
- Discovery looks for a MID Server that also has an appropriate IP range configured.
- If no MID Servers meet these criteria, it looks for a MID Server that has the ALL application that also has an appropriate IP range configured.
- If more than one MID Server meet the criteria, Discovery chooses the first MID Server with the status of Up. If more than one MID Server is up, it randomly picks one.
- If none are up, it uses the default MID Server specified for the Discovery application, assuming it is up.
- If no default MID Server is specified, it uses the default MID Server specified for the ALL application, assuming it is up.
- If no default MID Server is specified, Discovery cycles
through the previous steps and looks for MID Servers with the status of
Paused or Upgrading. Note:When a MID Server is paused or upgrading, it does not actually process commands until it returns to the status of Up.
MID Server clusters
- Discovery uses the first MID Server in the cluster that it finds with the status of Up.
- If more than one MID Server is up, it randomly picks one. If it cannot find any MID Servers, it looks for MID Servers in the cluster with the status of Paused or Upgrading.
- Discovery uses the MID Server with the lowest Order value that also has the status of Up.
- If no MID Servers are found, it looks for MID Servers in the cluster with the status of Paused or Upgrading, choosing the one with the lowest Order value.
Port scan (Shazzam) phase
During the port scan phase, Discovery collects all the target IP addresses. It splits them equally between MID Servers matching the criteria (MID Servers are qualified to do the port scan). The Shazzam batch size, which you configured on the Discovery schedule, determines the number of IP addresses that each Shazzam probe can scan. This phase helps determine how much work each MID Server does during the port scan phase.
For example, you have 16,000 IP addresses to scan among three qualified MID Servers, and you use the default Shazzam batch size of 5000. Two of the MID Servers handle 5000 IP address scans (one Shazzam probe each). The other MID Server handles 6000 IP address scans by launching two Shazzam probes.
Shazzam can process IP lists containing up to of 5000 addresses that include both IPv4 and IPv6 types. If your schedule contains an IP list with more than 5000 IPv6 IP addresses, the Discovery gets cancelled. If you are using only IPv6 addresses, you must use a list and not an IP address range. IPv6 address ranges and networks are not supported and will be ignored.