Get-VMReplication
Gets the replication settings for a virtual machine.
Get-VMReplication
[-CimSession <CimSession[]>]
[-ComputerName <String[]>]
[-Credential <PSCredential[]>]
[[-VMName] <String[]>]
[-ReplicaServerName <String>]
[-PrimaryServerName <String>]
[-ReplicationState <VMReplicationState>]
[-ReplicationHealth <VMReplicationHealthState>]
[-ReplicationMode <VMReplicationMode>]
[-ReplicationRelationshipType <VMReplicationRelationshipType>]
[-TrustGroup <String>]
[<CommonParameters>]
Get-VMReplication
[-VM] <VirtualMachine[]>
[-ReplicationRelationshipType <VMReplicationRelationshipType>]
[<CommonParameters>]
The Get-VMReplication cmdlet gets the replication settings for a virtual machine.
PS C:\> Get-VMReplication
This example gets the replication settings of all replication-enabled virtual machines on the local Hyper-V host.
PS C:\> Get-VMReplication VM01
This example gets the replication settings of a virtual machine named VM01.
PS C:\> Get-VMReplication -ReplicaServerName server01.domain01.contoso.com
This example gets the replication settings of all virtual machines replicating to server server01.domain01.contoso.com.
PS C:\> Get-VMReplication -ReplicationState Replicating
This example gets the replication settings of all virtual machines in the Replicating state.
PS C:\> Get-VMReplication -TrustGroup DEFAULT
This example gets the replication settings of all virtual machines in a trust group named DEFAULT.
PS C:\> Get-VMReplication -ReplicationMode Primary
This example gets the replication settings of all primary virtual machines on the local host.
Runs the cmdlet in a remote session or on a remote computer. Enter a computer name or a session object, such as the output of a New-CimSession or Get-CimSession cmdlet. The default is the current session on the local computer.
Type: | CimSession[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies one or more Hyper-V hosts from which virtual machine replication settings are to be retrieved. NetBIOS names, IP addresses, and fully qualified domain names are allowable. The default is the local computer. Use localhost or a dot (.) to specify the local computer explicitly.
Type: | String[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies one or more user accounts that have permission to perform this action. The default is the current user.
Type: | PSCredential[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the primary server of the virtual machines whose replication settings are to be retrieved.
Type: | String |
Aliases: | PrimaryServer |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the replica server name of the virtual machines whose replication settings are to be retrieved.
Type: | String |
Aliases: | ReplicaServer |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Gets replication settings for virtual machines with the specified replication health state. Valid values are Normal, Warning, and Critical.
Type: | VMReplicationHealthState |
Aliases: | Health |
Accepted values: | NotApplicable, Normal, Warning, Critical |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Gets the replication settings for virtual machines with the specified replication mode. Valid values are None, Primary, Replica, and TestReplica.
Type: | VMReplicationMode |
Aliases: | Mode |
Accepted values: | None, Primary, Replica, TestReplica, ExtendedReplica |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the replication relationship type of the virtual machine. Specify whether the replication relationship is a simple primary to replica or is an extended replication chain. The cmdlet gets the replication settings for the virtual machines that have the replication type that you specify.
Type: | VMReplicationRelationshipType |
Aliases: | Relationship |
Accepted values: | Simple, Extended |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Gets replication settings for virtual machines with the specified replication state. Valid values are:
- Error
- FailOverWaitingCompletion
- FailedOver
- NotApplicable
- ReadyForInitialReplication
- Replicating
- Resynchronizing
- ResynchronizeSuspended
- Suspended
- SyncedReplicationComplete
- WaitingForInitialReplication
- WaitingForStartResynchronize
Type: | VMReplicationState |
Aliases: | State |
Accepted values: | Disabled, ReadyForInitialReplication, InitialReplicationInProgress, WaitingForInitialReplication, Replicating, PreparedForFailover, FailedOverWaitingCompletion, FailedOver, Suspended, Error, WaitingForStartResynchronize, Resynchronizing, ResynchronizeSuspended, RecoveryInProgress, FailbackInProgress, FailbackComplete, WaitingForUpdateCompletion, UpdateError, WaitingForRepurposeCompletion, PreparedForSyncReplication, PreparedForGroupReverseReplication, FiredrillInProgress |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the trust group of the virtual machines whose replication settings you want to retrieve.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the virtual machine whose replication settings are to be retrieved.
Type: | VirtualMachine[] |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Specifies the name of the virtual machine whose replication settings are to be retrieved.
Type: | String[] |
Aliases: | Name |
Position: | 0 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Microsoft.HyperV.PowerShell.VMReplication