0

I'd like to select servers that are HP servers and start with NYCEX*. I looked at the following HP group and the query appears like this:

<Expression>
             <Contains>
                          <MonitoringClass>$MPElement[Name="HewlettPackard.Servers.HPServer"]$</MonitoringClass>
             </Contains>
</Expression>

How do I recreate that query and include a filter for a naming pattern, or AD OU?

makerofthings7
  • 8,911
  • 34
  • 121
  • 197

2 Answers2

1

It looks like you are looking for the following:

<Expression>
<RegExExpression>
<ValueExpression>
<Property>$MPElement[Name="Windows!Microsoft.Windows.Computer"]/DNSName$</Property>
</ValueExpression>
<Operator>MatchesWildcard</Operator>
<Pattern>NYCEX*</Pattern>
</RegExExpression>
</Expression>

I've used the DNSName, but you can also use the DisplayName as mentioned by Zach Bonham.

A nice way to learn how it is done in the XML is to follow the steps by Zach Bonham in the Authoring and save it to a unsealed MP, then export the unsealed MP from Administration | Management Packs. Then open it in a text editor. Then you'll see how the overall buildup is.

zhakal
  • 11
  • 1
0

It sounds like you are there?

I am not looking at the XML, but from the UI, have you tried creating a group, targeting the HewlettPackard.Servers.HPServer class (e.g. not just WindowsComputer), where the DisplayName Contains the pattern you are looking for?

You can always test the membership by viewing the Group Members from the Operations Console | Authoring tab | Groups menu.

Zach Bonham
  • 210
  • 1
  • 3
  • 10