OBLYTECH Logo
OBLYTECH Logo

Install and uninstall Nmap on a MID Server

To install and uninstall Nmap on a MID Server, use Enable Credential-less Discovery and Disable Credential-less Discovery on its record. Install Nmap on each supported Windows MID Server that will perform credential-less Discovery. Before installation, verify validation, Up status, local administrator access, and IP range coverage; afterward, check the version and capability.

Prepare the Windows host and discovery scope

The standard installation and removal procedure requires agent_admin. Windows administrator access is a separate host requirement: the MID Server must be logged in as a local administrator when Nmap is not already installed. Confirm that its status is Up, that it is validated, and that it does not already have the Nmap capability.

Inspect the MID Server installation path before starting. Parentheses, braces, and square brackets are unsuitable because the installer substitutes spaces for those characters and then cannot find the intended location. Resolve that path problem before attempting installation rather than treating it as an unexplained download failure.

Assign MID Server IP ranges across the deployment, then identify the ranges intended for credential-less Discovery. The Discovery Quick Start wizard includes Using MID Server IP range auto-assignment for establishing coverage. Record the relationship between the target ranges and the Windows MID Servers that can reach them. A successful installation on one host does not establish readiness for another host assigned to the same range.

For a broader rollout sequence, use the MID Server implementation roadmap to place host preparation before discovery testing. Check operating system support, installer versions, and property values against your instance and release before carrying out the change.

Match Nmap coverage to MID Server selection

Review the Discovery schedule selection before deciding how many installations are needed. A host inventory alone does not show which MID Server a schedule can select. Compare the assigned IP ranges with the chosen selection option and apply the corresponding coverage requirement.

  • Specific MID Cluster: Install Nmap on all cluster members and ensure that those members are configured for the same IP ranges.
  • Auto-Select Mid Server: For horizontal Discovery, at least one MID Server able to reach the schedule’s configured ranges must have Nmap installed.
  • Specific MID Server: Verify Nmap installation on each MID Server that can access the schedule’s configured MID Server IP Ranges.
  • All: Use Windows MID Servers with Nmap installed and ensure that they can reach the entire customer network.

Service Mapping needs particular attention. It selects a MID Server by IP address without checking for the Nmap capability. Install Nmap on all MID Servers assigned to the relevant ranges when credential-less Discovery is required for Service Mapping. Leaving an eligible host without Nmap can produce a discovery failure even though another host in the same range has a working installation.

Before approving the scope, write down the schedule, range, selection option, and eligible MID Servers together. This makes the coverage decision reviewable and helps identify a missing cluster member before the change. The MID Server governance model provides a place to organize ownership of those decisions.

Install Nmap and verify the stored result

  1. Navigate to All > MID Server > Servers and open the intended MID Server record.
  2. In Related Links, select Enable Credential-less Discovery.
  3. Choose Yes in the confirmation dialog to start installation.
  4. Inspect the Logs tab for Running system command: installNmap.
  5. If you dismiss the progress dialog with OK, allow the background installation to continue before assessing its result.

The installer also handles Npcap, the Windows packet capture library used by Nmap. If Npcap is absent, it is installed. An older installed version is upgraded, while a newer installed version is retained. Because Npcap is shared at the host level, include other applications that depend on packet capture in the host change review.

Use three record checks to accept the installation: Nmap version contains the installed version, the related link becomes Disable Credential-less Discovery, and Nmap appears under Capabilities. Capture these checks for the specific MID Server record rather than accepting the disappearance of the progress dialog as evidence of completion.

The Nmap capability represents an installed scanner. Adding a general capability entry is not a substitute for installing the software. The restricted self-hosted procedure has a separate maint-controlled capability step; keep that exception distinct from routine capability administration.

Investigate installation failures before repeating the action

An unsuccessful installation creates an entry in MID Server Issue [ecc_agent_issue]. Review that issue together with the MID Server Logs tab. Recheck the host account, installation path, validation, status, and download access against the preparation checklist. These checks connect the reported failure to the prerequisites without assuming that a missing capability is the original cause.

After correcting the cause, a successful installer run marks the issue Resolved. Record both the issue outcome and the successful record checks. A resolved issue explains the repair history; the version, changed related link, and capability show the resulting installation state.

If Service Mapping fails after installation succeeded elsewhere, inspect the MID Server chosen for the affected IP address. Compare that record with the complete eligible set. This separates a coverage gap from a failed installation on the host you already checked. Include that distinction in the handover using the MID Server best practices as a broader operational reference.

For help organizing the rollout, see ServiceNow implementation.

Uninstall Nmap without overlooking shared Npcap

For the standard procedure, use agent_admin and open the selected MID Server record. Under Related Links, select Disable Credential-less Discovery. During removal, the Logs tab shows Running system command: uninstallNmap. Keep the removal evidence with the installation record so that the change history identifies the affected MID Server.

Removing Nmap does not automatically remove Npcap. Before manually uninstalling Npcap, determine whether another application on the Windows host still depends on it. Treat that dependency review as a separate decision from disabling credential-less Discovery on one MID Server.

Before withdrawing Nmap from an eligible host, review the discovery schedules and range assignments that used it. Plan the resulting coverage deliberately, especially where Service Mapping can select that host by IP address. Keep the reason for removal, affected ranges, and subsequent verification together so the next operator can understand the intended state.

Handle self-hosted systems with blocked installer downloads

The manual route applies to self-hosted environments whose network prevents MID Server hosts from reaching the ServiceNow installer download service. The procedure lists admin, maint as required roles. Adding or removing the Nmap capability in this route specifically requires maint; admin alone does not authorize that capability change.

Open All > MID Server > Properties and read mid.nmap.version in MID Server Property [ecc_agent_property]. Obtain the matching installer through your approved transfer process. Create an nmap folder inside the MID Server agent folder, place the installer there, and rename it nmapInstaller.exe.

Run agent\scripts\PowerShell\NmapInstallation.ps1 using the ordered arguments below. Verify the script filename on the host before execution because the example naming can differ from the procedure’s filename.

  1. Set $operation to install.
  2. Provide $nmap_root_path as the complete nmap folder path.
  3. Provide $nmap_self_installer as the complete nmapInstaller.exe path.
  4. Set $nmap_command to the nmap.exe path inside that folder.
  5. Set $nmap_uninstall_command to the Uninstall.exe path inside that folder.
  6. Take $nmap_npcap_version from mid.nmap.npcap.version.
  7. Take $nmap_safe_scripts from mid.nmap.safe.scripts.

After installation, a maint user opens each relevant MID Server record, selects the Capabilities related list, chooses Edit, adds Nmap, and selects Save. For manual removal, run Uninstall.exe in the host’s nmap folder, delete that folder after uninstallation, and have a maint user remove Nmap from the active capabilities through Edit and Save.

Questions about Nmap prerequisites and host behavior

Which plugin supplies the installer integration?

Discovery – IP Based [com.snc.discovery.ip_based] supplies the installer connection and scripting elements. Activation of Discovery [com.snc.discovery] or Event Management and Service Mapping Core [com.snc.service-watch] also activates that plugin.

What information can credential-less Nmap discovery gather?

A configured Nmap command can resolve names through reverse DNS, discover MAC addresses, or collect operating system information from target CIs without target credentials. Choose the discovery purpose before interpreting the information collected.

Does running credential-less Discovery require permanent local administrator access?

After installation, non-admin users can run credential-less Discovery. Keep the temporary host privilege needed to install Nmap separate from the access used for ongoing operation.

Can another MID Server on the same Windows host enable the feature without an administrator?

If one MID Server on the shared host has already installed Nmap using an administrator account, other MID Servers there can enable credential-less Discovery using a non-admin user. Identify the host relationship before requesting additional elevation.