SNMP discovery in ServiceNow needs a credential the device accepts, a probe that knows which object identifiers to walk, and a MID Server that can reach the device. This guide covers each piece in the order you configure it: credentials and SNMP versions, probe tuning, MIB loading, and devices guarded by an access control list.
How the pieces fit together
An SNMP probe asks a device for a list of object identifiers (OIDs) and passes the results to sensors, which turn them into configuration item records. The ITOM discovery section covers the other probe types.
MID Servers support all SNMP versions by default, and you can narrow a MID Server to specific versions. Discovery supports versions 1, 2c and 3. If you select a version with no active credential behind it, the setting reverts to ALL. For routers and switches, the Network Router pattern replaces several older SNMP probes, so check the pattern list first.
Configuring SNMP credentials
SNMP community credentials have no user name. The password field holds the community string. Many devices answer to the read-only string public, which Discovery tries automatically, so you add a community credential when a device uses something else. Discovery tries each configured community string, though that does not extend to SNMPv3.
| Field | What to enter | Why it matters |
|---|---|---|
| Applies to | All MID servers, or Specific MID servers | Controls which MID Servers can see the credential |
| Order | A sequence number | Smaller numbers are tried first; equal or blank values are tried in random order |
| Credential alias | Optional name | Lets workflow creators assign the credential to Orchestration activities |
| External credential store | Checkbox | Replaces the user name and password with a Credential ID; CyberArk is the supported external store |
Choosing Specific MID servers limits the credential to the servers you list. Order deserves attention when you hold many credentials, or when security locks out users after three failed login attempts, so put the likeliest credential first.
Building an SNMPv3 credential
SNMPv3 credentials need a user name, an authentication protocol (MD5, SHA-1, SHA-224, SHA-256, SHA-384 or SHA-512) and a privacy protocol (3DES, AES128, AES192, AES256 or DES). Create the record from All > Discovery > Credentials, choose New, then SNMPv3 Credentials; the role required is admin. Your security level depends on which keys you fill in:
| Security option | Authentication | Privacy |
|---|---|---|
| noAuthNoPriv | Protocol None, key blank | Protocol None, key blank |
| authNoPriv | Protocol and key set | Protocol and key blank |
| authPriv | Protocol and key set | Protocol and key set |
The Use Context field adds a context name, which shows in the Discovery view. A context is a set of management information tied to a specific OID, and the manufacturer may supply it. If two devices share a user name and keys but one of them needs a context, create a separate record for each device. Contexts are not supported with external storage.
Setting the SNMP version on a schedule
A credential alone does not decide the version a scan uses. Open All > Discovery > Discovery schedules, choose the schedule, and set Use SNMP Version. The default is ALL; the other choices are v1, v2c and v3. Valid options follow your credentials: with an active SNMPv3 credential you can choose v3 or All, and with an active v1 or v2 community credential you can choose v1, v2c or All. Setting the version explicitly makes a scan easier to reason about when a device answers one version.
Tuning SNMP probe parameters
Probe parameters control how a probe behaves each time it runs. Open the probe, use the Probe Parameters related list, choose New, then enter a Name and a Value. The source parameter, the device’s IP address or host name, is required.
The parameter that shapes results is oid_spec_list. Each line takes one of two forms. The first, walk followed by an OID, walks that OID and its children. The second, table followed by an OID and a comma-separated list of children, walks the table entries and returns those children. A child can carry a filter in parentheses using =, != or #.
The timing parameters are the ones to adjust when a device is slow:
| Parameter | Default | What it controls |
|---|---|---|
| timeout | 1500 ms | How long to wait for a response |
| established_session_timeout | 500 ms | How long to wait once at least one response has arrived |
| request_interval | 400 ms | The gap between repeat requests for the same OID |
| request_delay | 0 ms | The pause between a response and the next request |
| index | 0 | Cisco-style community string indexing, used for VLAN queries |
Change timeout and request_interval together. When the interval is at least as long as the timeout, each OID gets a single request. Leave result_format at its JSON default: it applies to the F5 BIG-IP System, Netscaler System and Routing probes, and using it with other probes causes the sensor to fail.
Bulk and scalar retrieval
The use_getbulk parameter requests GETBULK instead of repeated GETNEXT calls when reading tables, which suits tabular data. A probe parameter overrides the MID Server configuration parameter, which overrides the MID Server property. Several switch probes and the ArpTable probe already use it by default, with a 5000 ms timeout.
With use_getbulk set to true, established_session_timeout, request_interval and request_delay are ignored, and retries (default 2) sets the number of additional attempts. The use_getscalar parameter, off by default, works similarly for scalar values.
Loading MIB modules
A management information base (MIB) is a database that describes the elements a device exposes. Your instance already includes many common MIBs, so check the existing list before you add an object definition. To load a new one, create an ecc_agent_mib record and attach the file. MIB files have no extension. MIBs load only when a MID Server starts, so a newly added MIB takes effect after the next startup. Loaded MIBs appear under MID Server > SNMP MIBs.
Discovering SNMP devices behind an ACL
An access control list on an SNMP device can stop Discovery from identifying it, because the ACL names the hosts allowed to run agents against it. The fix is a MID Server on a host the ACL permits.
- Install a MID Server on a host whose IP address is in the ACL. A server that scans SNMP alone can run on any supported operating system.
- Install a second MID Server for WMI and SSH on a Windows host that can see the target IP ranges. Add more MID Servers if you want load balancing.
- Create a Discovery Behavior record with a descriptive name and save it from the header bar. That creates the Discovery Functionality list.
- Add an SNMP functionality: phase 1, functionality SNMP only, the permitted MID Server, Active checked, and match criteria Any, since criteria are not used for SNMP.
- Add a second functionality: phase 1, All except SNMP, a Windows MID Server, and match criteria All. Its WMI scan needs two active criteria with the equals operator, mid_server (the server name) and win_domain (the domain name).
- Create a Discovery Schedule with Discover mode set to Configuration items, select the behavior, define ranges with Quick Ranges, and save.
Keeping both functionalities in phase 1 launches one probe for the whole phase, which keeps probe use efficient. For the credential side of host discovery, see the guide on credentials for host discovery.
Fortinet firewalls and SNMP discovery
The Next Generation Fortinet Network Firewall pattern finds Fortinet firewalls through a series of SNMP calls during horizontal discovery. It needs SNMP access on the firewall, SNMP credentials, and an SNMP system OID record with Fortinet Firewall as the classifier and Fortinet Firewall Device as the class.
The SNMP method has one limit to plan around: it does not discover FortiGate virtual domains (VDOMs). The REST-based method does. To switch, go to All > Discovery Definition > CI Classification > SNMP, search Name for Fortinet Firewall, open the record, clear Active and save. Then create an alias and add it to an API key credential.
Reducing switch port collection
Some network devices carry a very large number of ports. To stop collecting per-port data, go to Discovery Definition > Probes, open SNMP – Switching, and on the SNMP Fields tab set the ports field’s Active value to false. The switch record keeps the correct ports count, but the switchports related list, backed by the dscy_switchport table, stays empty. The change affects probe discovery alone.
Frequently asked questions
Why does Discovery try the public string?
Many SNMP devices default to public as the read-only community string, so Discovery tries it automatically. Add your own string when a device uses another one.
Does an SNMPv3 credential also need the schedule version set?
Yes. Set Use SNMP Version on the schedule as well. If you select v3 with no active v3 credential, the setting reverts to ALL.
Do I need a second MID Server for WMI and SSH behind an ACL?
Yes. Use a second MID Server for WMI and SSH, placed on a Windows host that can see the target IP ranges, alongside a separate SNMP-only MID Server on a host the ACL permits. The SNMP host can run on any supported operating system because it scans SNMP alone. WMI needs a Windows host with visibility to the domain, so the second server sits there.
Does SNMP-based Fortinet discovery find FortiGate virtual domains?
No. The SNMP method does not find them, so use the REST-based method for that.
Set up credentials and versions first, confirm a single device responds, then tune probe parameters if results are slow or incomplete. If you would rather have that work handled for you, see the discovery implementation page.