WMI credentials fail on MID server host
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-03-2020 08:08 AM
I am unable to discover the host a MID server is running on. The WMI credential works on other windows servers, but fails when tested against the MID server IP. When discovery runs, it stops during classify and the logs show that no credential_id for that host .
I can login to the MID server host with the discovery credential. I can run WMI queries on the host using the credential.
? Is there some reason a MID server cannot discover itself in New York?
? What is the actual test that runs when "test credential" is run?
- Labels:
-
Discovery

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-03-2020 08:16 AM
Hello
Perhaps one of these related posts will help you solve the credentials issue:
Hope that helps!
If it did, please mark as Helpful and consider setting the reply as the Correct Answer to the question, thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-03-2020 10:00 AM
There is nothing wrong with the credential - it is working on other targets and it works on the MID server, just not for discovery. Digging deeper, it seems that PowerShell will not accept a credential for the local computer.
gwmi win32_operatingsystem -computer 127.0.0.1
works but
gwmi win32_operatingsystem -computer 127.0.0.1 works -credential domain\user
generates the error
Get-WmiObject : User credentials cannot be used for local connections
So, unless there is a way for ServiceNow to recognize that the MID server is discovering itself and drop the -credential argument, I guess it is necessary to add another MID server and have each MID discover the other.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-03-2020 10:48 AM
Discovering the MID server from another MID server works, but seems a bit crazy that it is necessary.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-14-2022 02:44 PM
This is because you cannot discover the server itself using credentials. Power-shell will not accept it and will throw a warning saying credentials cannot be used to local connections.
<?xml version="1.0" encoding="UTF-8"?><results probe_time="6828" result_code="0"><result><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local connections </Warning><Warning>User credentials cannot be used for local
Try to discover by using another mid server or You can Update the credentials to run the service account similar to discovery_credentials
It will always use the credentials the mid server service is running with when you discover itself.
Regards,
Nayan