Edit

Share via


Get-ShieldedVMProvisioningStatus

Queries the provisioning status of a shielded virtual machine.

Syntax

ByName (Default)

Get-ShieldedVMProvisioningStatus
    [-VMName] <String>
    [<CommonParameters>]

ByVM

Get-ShieldedVMProvisioningStatus
    [-VM] <VirtualMachine>
    [<CommonParameters>]

ByInstance

Get-ShieldedVMProvisioningStatus
    -ProvisioningJob <CimInstance>
    [<CommonParameters>]

Description

The Get-ShieldedVMProvisioningStatus cmdlet queries the provisioning status of a shielded virtual machine.

Examples

Example 1: Get the provisioning job status for a virtual machine

PS C:\>Get-ShieldedVMProvisioningStatus -VMName "MyVM"

This command gets the provisioning job status for the virtual machine named MyVM.

Example 2: Get the provisioning job status for a virtual machine using a variable

PS C:\>$VM = Get-VM -VMName "MyVM"
Get-ShieldedVMProvisioningStatus -VM $VM

The first command gets the virtual machine named MyVM and stores it in the variable named $VM.

The second command gets the provisioning job status for the virtual machine stored in the variable named $VM.

Example 3: Get the provisioning job status for a virtual machine using an existing provisioning job object

PS C:\>$Job = Get-ShieldedVMProvisioningStatus -VMName "MyVM"
Get-ShieldedVMProvisioningStatus -ProvisioningJob $Job

The first command gets the provisioning job status for the virtual machine named MyVM and stores it in the variable named $Job.

The second command calls Get-ShieldedVMProvisioningStatus again using the provisioning job status stored in the $Job variable.

Parameters

-ProvisioningJob

Specifies a CimInstance object returned from either the Initialize-ShieldedVM cmdlet or a prior call to the Get-ShieldedVMProvisioningStatus cmdlet.

Parameter properties

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

Parameter sets

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

-VM

Specifies the virtual machine that this cmdlet provisions.

Parameter properties

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

Parameter sets

ByVM
Position:1
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VMName

Specifies the name of the virtual machine that this cmdlet provisions.

Parameter properties

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

Parameter sets

ByName
Position:1
Mandatory:True
Value from pipeline:False
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.