So i wondered if somehow was possible to know to which DA a specific server belongs to, and came up with this 'idea' (poweshell script!):
Import-Module OperationsManager
$list = Get-SCOMClass -DisplayName "DA - NAME - HERE" | Get-SCOMClassInstance | %{$_.GetRelatedMonitoringObjects()} | %{$_.GetMonitoringRelationshipObjects()} | select SourceMonitoringObject, TargetMonitoringObject
ForEach ($i in $list) {
If ( $i.TargetMonitoringObject.DisplayName -eq 'SERVER_FQDN' ) {
$DA += $i.SourceMonitoringObject.DisplayName + ' || '
}
}
Enjoy :)
No comments:
Post a Comment