Get-SCManagementPack
从 Operations Manager 环境中获取 System Center Operations Manager 管理包。
语法
Get-SCManagementPack
[-SCSession <Connection[]>]
[-ComputerName <String[]>]
[-Credential <PSCredential>]
[<CommonParameters>]
Get-SCManagementPack
[-BundleFile] <String[]>
[-SCSession <Connection[]>]
[-ComputerName <String[]>]
[-Credential <PSCredential>]
[<CommonParameters>]
Get-SCManagementPack
[-ManagementPackFile] <String[]>
[-SCSession <Connection[]>]
[-ComputerName <String[]>]
[-Credential <PSCredential>]
[<CommonParameters>]
Get-SCManagementPack
[-DisplayName] <String[]>
[-Recurse]
[-SCSession <Connection[]>]
[-ComputerName <String[]>]
[-Credential <PSCredential>]
[<CommonParameters>]
Get-SCManagementPack
[-Id] <Guid[]>
[-Recurse]
[-SCSession <Connection[]>]
[-ComputerName <String[]>]
[-Credential <PSCredential>]
[<CommonParameters>]
Get-SCManagementPack
[-Name] <String[]>
[-Recurse]
[-SCSession <Connection[]>]
[-ComputerName <String[]>]
[-Credential <PSCredential>]
[<CommonParameters>]
说明
Get-SCManagementPack cmdlet 获取 System Center Operations Manager 管理包。 也可以使用 执行 Get-SCOMManagementPack
此命令。
默认情况下,此 cmdlet 使用与管理组的活动持久连接。 使用 SCSession 参数指定不同的持久连接。 可以使用 ComputerName 和 Credential 参数创建与管理组的临时连接。 要了解详情,请键入 Get-Help about_OpsMgr_Connections
。
示例
1:使用其名称获取 System Center Operations Manager 管理包
PS C:\>Get-SCManagementPack -Name "*Microsoft.Windows.Server*"
使用带有通配符的名称获取 System Center Operations Manager 管理包。
2:使用其显示名称获取 System Center Operations Manager 管理包
PS C:\>Get-SCManagementPack -DisplayName "*Windows Server 2016 and above*"
使用带有通配符的显示名称获取 System Center Operations Manager 管理包。 对于多个显示名称,可以使用逗号分隔这些项。
3:使用其 ID 获取 System Center Operations Manager 管理包
PS C:\>Get-SCManagementPack -Id 25bdd09a-bda3-d94b-b8c1-d450834b5bad
使用其 ID 获取 System Center Operations Manager 管理包。 对于多个 ID,可以使用逗号分隔这些项。
4:使用文件获取 System Center Operations Manager 管理包
PS C:\>Get-SCManagementPack -ManagementPackFile "${env:ProgramFiles(x86)}\System Center Management Packs\Microsoft System Center MP for WS 2016 and above\Microsoft.Windows.Server.2016.Discovery.mp"
使用管理包文件获取 System Center Operations Manager 管理包。 对于多个文件,可以使用逗号分隔这些项。
参数
-BundleFile
Type: String [ ]
Position: 1
Default value: None
Required: True
Accept pipeline input: False
Accept wildcard characters: False
-ComputerName
Type: String [ ]
Position: Named
Default value: None
Required: False
Accept pipeline input: False
Accept wildcard characters: False
-Credential
Type: PSCredential
Position: Named
Default value: None
Required: False
Accept pipeline input: False
Accept wildcard characters: False
-DisplayName
Type: String [ ]
Position: 1
Default value: None
Required: True
Accept pipeline input: False
Accept wildcard characters: False
-Id
Type: Guid [ ]
Position: 1
Default value: None
Required: True
Accept pipeline input: True
Accept wildcard characters: False
-ManagementPackFile
Type: String [ ]
Position: 1
Default value: None
Required: True
Accept pipeline input: False
Accept wildcard characters: False
-Name
Type: String [ ]
Position: 1
Default value: None
Required: True
Accept pipeline input: True
Accept wildcard characters: False
-Recurse
Type: SwitchParameter
Position: 2
Default value: None
Required: False
Accept pipeline input: False
Accept wildcard characters: False
-SCSession
Type: Connection [ ]
Position: Named
Default value: None
Required: False
Accept pipeline input: False
Accept wildcard characters: False