- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi All,
I would like some clarification on the expected behavior for ServiceNow Discovery when discovering new Windows SQL Servers.
Current Database Discovery:
We are now implementing SQL Server Discovery and plan to reuse the same Windows service account using Windows Authentication.
The DBA team has already:
- Granted the required SQL access (VIEW SERVER STATE)
- Provided a list of non-production SQL Servers for testing
Issue
When I run Quick Discovery against one of the pilot SQL servers, Discovery fails during the Windows Classification phase
Could not find any valid credentials to authenticate the target for type [Windows]
Active, couldn't classify: No WMI connectionFrom the WMI Runner logs:
- ServiceNow successfully finds and attempts the Windows credential
- All credential attempts fail authentication
- TCP 135 is open
- WinRM (5985) is open
- DNS resolution is successful
My Question
My understanding was that since the Windows Discovery service account already has the required permissions, I should only need to grant the additional SQL permissions for Database Discovery.
However, based on the behavior, it appears that the SQL pilot servers may require the same Windows Discovery onboarding/configuration to be applied individually on those servers.
Could someone clarify:
- Are permissions such as DCOM, WMI namespace access, Distributed COM Users, Performance Monitor Users, etc., typically configured on each target server?
- If a service account already works for Windows Discovery on one set of servers, should it automatically work on other Windows servers?
Any guidance would be appreciated.
Thanks in advance.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi @Aman_07
Those WMI/DCOM permissions live locally on each server — they don't travel with the service account. So even though your account already has AD-level access and works on your original servers, each new server needs those same local permissions set up on it individually (usually via a GPO scope or manual config).
Confirm with your Windows/AD team whether the pilot SQL servers are in the same OU/GPO scope as your original Discovery servers. If not, apply the same GPO (or manually configure DCOM/WMI/local group permissions) to the pilot servers, then re-run Quick Discovery
Please Accept the solution if it assisted you with your question & Mark this response as Helpful.
Regards
Bharat Chavan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
a week ago
Hi @BharatC
Error observed
When the pattern attempts to execute commands such as:
wmic /NAMESPACE:\\root\Microsoft\SqlServer\ComputerManagement15 PATH SqlServiceAdvancedProperty GET PropertyName,PropertyNumValue,PropertyStrValue,ServiceName,SqlServiceType /VALUEwe receive the following error:
Test-Path : Access is denied
At:
...\agent\scripts\PowerShell\SecureTempFolder.psm1:64 char:9
if (Test-Path -Path $folder -PathType Container)
CategoryInfo : NotSpecified: (:) [Test-Path], UnauthorizedAccessException
FullyQualifiedErrorId : System.UnauthorizedAccessException,Microsoft.PowerShell.Commands.TestPathCommandCurrent Validation
The following has been confirmed:
- Windows Server Discovery is successful.
- sqlservr.exe is detected on the target server.
- The root\Microsoft\SqlServer WMI namespace is accessible.
- ComputerManagement15 is successfully identified.
- Failure occurs when the pattern attempts further command execution during Collect MSSQL Components Info using Utility.
- The error consistently references SecureTempFolder.psm1 and Test-Path : Access is denied.
- Because this MSSQL collection step fails, the complete MSSQL Database Discovery flow is not proceeding successfully.
Any idea about this?
- Does this error indicate that the Discovery credential requires additional access to a remote temporary folder or Windows administrative share on the target server?
- What minimum permissions are required for the Discovery credential to allow the MSSQL pattern commands to execute successfully without granting full administrator access
