編集

次の方法で共有


Add-AzExpressRouteCircuitConnectionConfig

Adds a circuit connection configuration to Private Peering of an Express Route Circuit.

Syntax

Add-AzExpressRouteCircuitConnectionConfig
   [-Name] <String>
   [-ExpressRouteCircuit] <PSExpressRouteCircuit>
   [-AddressPrefix] <String>
   [-AddressPrefixType <String>]
   [-AuthorizationKey <String>]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Add-AzExpressRouteCircuitConnectionConfig
   [-Name] <String>
   [-ExpressRouteCircuit] <PSExpressRouteCircuit>
   [-PeerExpressRouteCircuitPeering] <String>
   [-AddressPrefix] <String>
   [-AddressPrefixType <String>]
   [-AuthorizationKey <String>]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

The Add-AzExpressRouteCircuitConnectionConfig cmdlet adds a circuit connection configuration to private peering for an ExpressRoute circuit. This allows peering two Express Route Circuits across regions or subscriptions.Note that, after running Add-AzExpressRouteCircuitConnectionConfig, you must call the Set-AzExpressRouteCircuit cmdlet to activate the configuration.

Examples

Example 1: Add a circuit connection resource to an existing ExpressRoute circuit

$circuit_init = Get-AzExpressRouteCircuit -Name $initiatingCircuitName -ResourceGroupName $rg
$circuit_peer = Get-AzExpressRouteCircuit -Name $peeringCircuitName -ResourceGroupName $rg
$addressSpace = '60.0.0.0/29'
$addressPrefixType = 'IPv4'
Add-AzExpressRouteCircuitConnectionConfig -Name $circuitConnectionName -ExpressRouteCircuit $circuit_init -PeerExpressRouteCircuitPeering $circuit_peer.Peerings[0].Id -AddressPrefix $addressSpace -AddressPrefixType $addressPrefixType -AuthorizationKey $circuit_peer.Authorizations[0].AuthorizationKey
Set-AzExpressRouteCircuit -ExpressRouteCircuit $circuit_init

Example 2: Add a circuit connection configuration using Piping to an existing ExpressRoute Circuit

$circuit_peer = Get-AzExpressRouteCircuit -Name $peeringCircuitName -ResourceGroupName $rg
$addressSpace = '60.0.0.0/29'
Get-AzExpressRouteCircuit -Name $initiatingCircuitName -ResourceGroupName $rg|Add-AzExpressRouteCircuitConnectionConfig -Name $circuitConnectionName -PeerExpressRouteCircuitPeering $circuit_peer.Peerings[0].Id -AddressPrefix $addressSpace -AuthorizationKey $circuit_peer.Authorizations[0].AuthorizationKey |Set-AzExpressRouteCircuit

Parameters

-AddressPrefix

A minimum /29 customer address space to create VxLan tunnels between Express Route Circuits for IPv4 tunnels. or a minimum of /125 customer address space to create VxLan tunnels between Express Route Circuits for IPv6 tunnels.

Type:String
Position:3
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-AddressPrefixType

This specifies the Address Family that address prefix belongs to.

Type:String
Accepted values:IPv4, IPv6
Position:Named
Default value:IPv4
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-AuthorizationKey

Authorization Key to peer Express Route Circuit in another subscription. Authorization on peer circuit can be created using existing commands.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with azure.

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ExpressRouteCircuit

The ExpressRoute circuit being modified. This is Azure object returned by the Get-AzExpressRouteCircuit cmdlet.

Type:PSExpressRouteCircuit
Position:1
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Name

The name of the circuit connection resource to be added.

Type:String
Position:0
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-PeerExpressRouteCircuitPeering

Resource Id for Private Peering of remote circuit which will be peered with the current circuit.

Type:String
Position:2
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

PSExpressRouteCircuit

String

Outputs

PSExpressRouteCircuit