Get-WBVirtualMachine
Gets all virtual machines and components from the backup policy.
Syntax
Default (Default)
Get-WBVirtualMachine
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Policy
Get-WBVirtualMachine
[[-Policy] <WBPolicy>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Get-WBVirtualMachine cmdlet gets all virtual machines and Hyper-V Server components from the WBPolicy object or the physical computer.
Examples
Example 1: Get all virtual machines and components from the backup policy
PS C:\> Get-WBVirtualMachine
This command queries for virtual machines and Hyper-V Server 2016 components on the machine and lists them.
Parameters
-Confirm
Prompts you for confirmation before running the cmdlet.
Parameter properties
Type: | SwitchParameter |
Default value: | False |
Supports wildcards: | False |
DontShow: | False |
Aliases: | cf |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Policy
Specifies the backup policy information contained in the WBPolicy object to display.
Parameter properties
Type: | WBPolicy |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
Policy
Position: | 0 |
Mandatory: | False |
Value from pipeline: | True |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Parameter properties
Type: | SwitchParameter |
Default value: | False |
Supports wildcards: | False |
DontShow: | False |
Aliases: | wi |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
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.