My powershell was wrong, it should read like this (although, I still don’t get
any results)
Import-Module OperationsManager
New-SCOMManagementGroupConnection “FQDN OF MS”
(get-SCOMagent | where {$_.PrimaryManagementServerName -eq “FQDN OF THE MS/GW”}
| ft name)
Thanks,
Blake
From: [email protected] [mailto:[email protected]] On
Behalf Of Blake Wilson
Sent: Thursday, August 20, 2015 12:03 PM
To: [email protected]
Subject: [msmom] PowerShell Widget View
I’m trying to create a view in OpsMgr 2012 R2 that uses the PowerShell Grid
widget. What we’re going after seems simple enough; we want to show what agents
report to a specific MS or GW. I’m using the powershell script below, but I’m
not getting ANY results in the widget.
Import-Module OperationsManager
New-SCOMManagementGroupConnection “MANAGEMENT GROUP NAME”
(get-SCOMagent | where {$_.PrimaryManagementServerName -eq “FQDN OF THE MS”} |
ft name)
Any suggestions?
Thanks,
Blake