Delen via


Get-SCComplianceStatus

Gets the compliance status of computers managed by VMM.

Syntax

All (Default)

Get-SCComplianceStatus
    [-VMMServer <ServerConnection>]
    [-All]
    [<CommonParameters>]

VMMManagedComputer

Get-SCComplianceStatus
    -VMMManagedComputer <VMMManagedComputer>
    [-VMMServer <ServerConnection>]
    [<CommonParameters>]

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.

Examples

Example 1: Get the compliance status of a host

PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost01"
PS C:\> $Compliance = Get-SCComplianceStatus -VMMManagedComputer $VMHost.ManagedComputer
PS C:\> $Compliance

The first command gets the host object named VMHost01 and stores the object in the $VMHost variable.

The second command gets the compliance status object for the host stored in $VMHost01 and stores the object in the $Compliance variable.

The last command displays information about the compliance status of VMHost01 to the user.

Parameters

-All

Indicates that this cmdlet gets all subordinate objects independent of the parent object. For example, the command Get-SCVirtualDiskDrive -All gets all virtual disk drive objects regardless of the virtual machine object or template object that each virtual disk drive object is associated with.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

All
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VMMManagedComputer

Specifies a computer object that is managed by VMM.

Parameter properties

Type:VMMManagedComputer
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

VMMManagedComputer
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-VMMServer

Specifies a VMM server object.

Parameter properties

Type:ServerConnection
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Outputs

ComplianceStatus

This cmdlet returns a ComplianceStatus object.