Stop-AzVirtualNetworkGatewaySiteFailoverTest
Stops the failover simulation on the virtual network gateway for the specified peering location.
Syntax
Default (Default)
Stop-AzVirtualNetworkGatewaySiteFailoverTest
-ResourceGroupName <String>
-VirtualNetworkGatewayName <String>
-PeeringLocation <String>
-WasSimulationSuccessful <Boolean>
-Detail <System.Collections.Generic.List`1[Microsoft.Azure.Management.Network.Models.FailoverConnectionDetails]>
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Stop-AzVirtualNetworkGatewaySiteFailoverTest cmdlet is used to stop a failover simulation that was previously initiated for the virtual network gateway. The test is identified by the PeeringLocation where the test was run.
When stopping the test, you must provide whether the simulation was successful using the -WasSimulationSuccessful parameter, and you must also supply detailed information about the failover simulation using the -Detail parameter.
This cmdlet allows you to conclude the failover test and capture any important information about the simulation results, including whether the test was successful or not.
Examples
Example 1
$detail = @(
[Microsoft.Azure.Management.Network.Models.FailoverConnectionDetails]@{
FailoverConnectionName = "test_failover_gateway_connection"
FailoverLocation = "eastus2"
IsVerified = $true
}
)
Stop-AzVirtualNetworkGatewaySiteFailoverTest -ResourceGroupName "test_failover_rg" -VirtualNetworkGatewayName "test_failoverGw" -PeeringLocation "WestEurope" -Detail $detail -WasSimulationSuccessful $true
This example demonstrates how to stop a failover simulation for a virtual network gateway. The cmdlet Stop-AzVirtualNetworkGatewaySiteFailoverTest is used with the following parameters:
ResourceGroupName: Specifies the resource group ("test_failover_rg") that contains the virtual network gateway.
VirtualNetworkGatewayName: Specifies the virtual network gateway ("test_failoverGw") for which the failover test is being stopped.
PeeringLocation: Specifies the peering location ("WestEurope") where the failover test is being stopped.
Detail: The failover connection details are provided, including the name, location, and verification status.
WasSimulationSuccessful: Indicates that the failover simulation was successful ($true).
Parameters
-Confirm
Prompts you for confirmation before running the cmdlet.
Parameter properties
| Type: | SwitchParameter |
| Default value: | None |
| 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 |
-DefaultProfile
The credentials, account, tenant, and subscription used for communication with Azure.
Parameter properties
| Type: | IAzureContextContainer |
| Default value: | None |
| Supports wildcards: | False |
| DontShow: | False |
| Aliases: | AzContext, AzureRmContext, AzureCredential |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | False |
| Value from pipeline: | False |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
-Detail
Details of the failover simulation.
Parameter properties
| Type: | |
| Default value: | None |
| Supports wildcards: | False |
| DontShow: | False |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | True |
| Value from pipeline: | False |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
-PeeringLocation
Peering location of the failover test to stop.
Parameter properties
| Type: | String |
| Default value: | None |
| Supports wildcards: | False |
| DontShow: | False |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | True |
| Value from pipeline: | False |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
-ResourceGroupName
The resource group name of the virtual network gateway.
Parameter properties
| Type: | String |
| Default value: | None |
| Supports wildcards: | False |
| DontShow: | False |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | True |
| Value from pipeline: | False |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
-VirtualNetworkGatewayName
The name of the virtual network gateway.
Parameter properties
| Type: | String |
| Default value: | None |
| Supports wildcards: | False |
| DontShow: | False |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | True |
| Value from pipeline: | False |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
-WasSimulationSuccessful
Whether the simulation was successful.
Parameter properties
| Type: | Boolean |
| Default value: | None |
| Supports wildcards: | False |
| DontShow: | False |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | True |
| Value from pipeline: | False |
| 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: | None |
| 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.