Company policy requires that every Server has an administrator assigned. This information is being saved in the "Managed by" Field in the Computer Object.
It would be pretty useful to create a dynamic group in SCOM which is being populated via this AD Field. And therein lies my problem.
Steps I have tried to far.
1.Create a Attribute "Managed by" for the Windows-Computer target. This Attribute is being by the WMI Query SELECT * FROM DS_computer
with the property DS_managedBy
.
2.Create a group with a dynamic filter. (Object is Windows-Computer_Extended AND (Managed by Equals usr) AND True)
Now this seems reasonable in theory but apparently doesn't work at all.
Is this actually possible what I am trying to create? How am I tackling this problem?
After some research I found that someone already tackled this problem. Sort of. I modified this script. Got rid of the last couple of lines and added the logic below I needed. It is messy but it works like a charm. All you need to change is the management server and the inclusion regex (we have multiple domains but only want this sort of automation for one).