Let me turn this around on you. How do you know SCOM is installed on a computer? Once you answer that we can point you to making the WQL query.
WQL query for Device collection of SCOM managemnet servers and/or device collection of SCOM gateways
I would like to create a SCCM dynamic device collection that includes SCOM management servers and another one that includes gateway servers? What WQL query I can use for this? are there any queries already available?
Sign in to comment
Sort by: Most helpful
Well, that's what I'm trying to figure out. I tried running a query for the Uninstall entry, but it didn't work. So, I was wondering if we have a ready recipe?
Based on your reply, you do normally see something when you interactively look at a server, at Programs and Features, correct? Maybe you aren't looking at the "right" thing for CM. If you look in the console, pick a specific server that you personally KNOW has management server and/or gateway server installed, and right-click look at "resource explorer" for that specific device, you should see it listed under "Installed Software".
If it's not there, look at all of the other things in resource explorer. Potential other ways to "tell" might be if there is a unique service under Services (if you inventory services).
Hi @D D ,
I have done some tests and research on your question. We can query it by the special services used by SCOM management servers and gateway servers.
1, Make sure that the service information is collected by "Hardware Inventory" Client Settings. For example:
(By default, "Default Client Settings" already contains these. If not, please create it manually)
2, Run hardware inventory to gather service information.
3, Then run following query:
> Select SMS_R_System.Name, SMS_G_System_SERVICE.DisplayName from SMS_R_System inner join SMS_G_System_SERVICE on SMS_G_System_SERVICE.ResourceId = SMS_R_System.ResourceId where DisplayName = "Servicename"
Below is an example with a service, just for your reference:
This thread for your reference:
SCCM CB | WQL Query to find the specific Service is Running (microsoft.com)
Looking forward to your feedback.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
I'm writing to see if this method has solved your issue. If there's anything else we can help please feel free to let us know, we will do our best to help you.
Thanks for your time.
Sign in to comment