Get-SCComplianceStatus
Get-SCComplianceStatus
Gets the compliance status of computers managed by VMM.
Syntax
Parameter Set: All
Get-SCComplianceStatus [-All] [-VMMServer <ServerConnection> ] [ <CommonParameters>]
Parameter Set: VMMManagedComputer
Get-SCComplianceStatus -VMMManagedComputer <VMMManagedComputer> [-VMMServer <ServerConnection> ] [ <CommonParameters>]
Detailed Description
The Get-SCComplianceStatus cmdlet gets the compliance status object of one or more computers managed by Virtual Machine Manager (VMM). The returned compliance status provides details on the compliance against assigned baselines.
Parameters
-All
Indicates that this cmdlet retrieves a full list of all subordinate objects independent of the parent object. For example, the command Get-SCVirtualDiskDrive -All
retrieves all virtual disk drive objects regardless of the virtual machine object or template object that each virtual disk drive object is associated with.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-VMMManagedComputer<VMMManagedComputer>
Specifies a computer object that is managed by VMM.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
Accept Wildcard Characters? |
false |
-VMMServer<ServerConnection>
Specifies a VMM server object.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
Accept Wildcard Characters? |
false |
<CommonParameters>
This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).
Inputs
The input type is the type of the objects that you can pipe to the cmdlet.
Outputs
The output type is the type of the objects that the cmdlet emits.
- ComplianceStatus
Examples
Example 1: Get the compliance status of a host
The first command gets the host object named VMHost01, and then stores the object in the $VMHost variable.
The second command gets the compliance status object for the host stored in $VMHost01, and then stores the object in the $Compliance variable.
The last command displays information about the compliance status of VMHost01.
PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost01"
PS C:\> $Compliance = Get-SCComplianceStatus -VMMManagedComputer $VMHost.ManagedComputer
PS C:\> $Compliance