Window server host name is incorrect in ServiceNow discovery
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
Name of the windows server is reflecting its IP address rather then the name of the CI, as checked same ip we are getting the correct name for the Virtual machine but the name is getting changed for the windows server .
Cna someone help with the solution to correct the Hostname for the windows server, as currenly everything looks good at servicenow end.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
Hi @NeelH ,
Based on your screenshot and the issue description, the root cause is most likely that ServiceNow Discovery is failing to retrieve the proper hostname from the Windows server, so it’s falling back to the IP address as the Name in the CI record. This can happen when WMI/WinRM queries do not return the hostname or fqdn during the classification/identification phase.
Also can be possibilities on windows server level Hostname is configured like that way only which you showcased in screenshot , below solutions option will help you to find the root cause and fix.
1. Check Discovery Patterns / Probes for Windows
* Go to Patterns (if using Pattern-based Discovery) or Probes (if using Legacy Probe/Classifier).
* Look at the Windows OS - Identify or Windows OS - Classify step.
* Ensure it’s correctly fetching host_name or fqdn from the target.
* If the script is returning blank, Discovery will set the CI Name to IP.
2. Verify Connectivity & Permissions
* For WMI: Ports 135 & 49152–65535 must be open.
* For WinRM: Ports 5985 (HTTP) or 5986 (HTTPS) must be open.
* Ensure your Discovery credentials have local administrator rights.
* From the MID Server, run:
Powershell Command - winrm id -r:<IP_ADDRESS> -u:<USER> -p:<PASSWORD>
and
Powershell Command - hostname
to confirm the server returns its actual hostname.
3. Check IRE Rules
* Go to Identification and Reconciliation Rules for cmdb_ci_win_server.
* Confirm that Name is not set to override with IP if hostname is blank.
* Ensure Serial Number + Name is being used for matching.
4. Check for DNS Resolution
* Sometimes MID Server fails to resolve the hostname from IP.
* On MID Server host, run:
Powershell Command - nslookup 10.134.80.110
* If DNS does not return a valid hostname, Discovery may store the IP.
5. Force Update After Fix
* Once connectivity & pattern issues are fixed, run a Rediscovery for the affected IP range.
* If needed, manually update Name for affected records in cmdb_ci_win_server and allow IRE to merge future discoveries.
Please appreciate the efforts of community contributors by marking appropriate response as Mark my Answer Helpful or Accept Solution this may help other community users to follow correct solution in future.
Thank You
AJ - TechTrek with AJ - ITOM Trainer
LinkedIn:- https://www.linkedin.com/in/ajay-kumar-66a91385/
YouTube:- https://www.youtube.com/@learnitomwithaj
Topmate:- https://topmate.io/aj_techtrekwithaj (Connect for 1-1 Session)
ServiceNow Community MVP 2025
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
@NeelH You can do a quick discovery to this IP address and Check under the 'Discovery Log' tab, open the Pattern Log by click on the link provided under the short Message "Exploring CI Pattern, Pattern name: Windows OS - Servers, To Check Pattern Log Press Here". A separate window opens, and search for the string (you can do a simple browser search) "Hostname=". That will exactly show you how the Hostname is grabbed. Example from my testing window looks like this:
2025-08-13 20:52:32: Got registry response: Hostname=Clabs-Windows Domain= Key=SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Hostname{!|#?}Domain
Do let us know if this didn't help you. Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi @NeelH - check DNS from the mid sever run below command on Powershell .
nslookup 10.134.80.110
and verify it matches the expected hostname in additional check the point @AJ-TechTrek mentioned
if my answer helps you mark helpful and accept solution