Set-AzExpressRouteGateway

Ölçeklenebilir Bir ExpressRoute Ağ Geçidi Güncelleştirmeler.

Syntax

Set-AzExpressRouteGateway
   -ResourceGroupName <String>
   -Name <String>
   [-MinScaleUnits <UInt32>]
   [-MaxScaleUnits <UInt32>]
   [-Tag <Hashtable>]
   [-AsJob]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Set-AzExpressRouteGateway
   -InputObject <PSExpressRouteGateway>
   [-MinScaleUnits <UInt32>]
   [-MaxScaleUnits <UInt32>]
   [-Tag <Hashtable>]
   [-AsJob]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Set-AzExpressRouteGateway
   -ResourceId <String>
   [-MinScaleUnits <UInt32>]
   [-MaxScaleUnits <UInt32>]
   [-Tag <Hashtable>]
   [-AsJob]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

Set-AzExpressRouteGateway cmdlet'i mevcut bir ExpressRouteGateway için ölçek birimlerini güncelleştirmenizi veya kaynak etiketlerini güncelleştirmenizi sağlar.

Örnekler

Örnek 1

New-AzResourceGroup -Location "West US" -Name "testRG"
$virtualWan = New-AzVirtualWan -ResourceGroupName testRG -Name myVirtualWAN -Location "West US"
$virtualHub = New-AzVirtualHub -VirtualWan $virtualWan -ResourceGroupName "testRG" -Name "westushub" -AddressPrefix "10.0.0.1/24"
New-AzExpressRouteGateway -ResourceGroupName "testRG" -Name "testergw" -VirtualHubId $virtualHub.Id -MinScaleUnits 2
Set-AzExpressRouteGateway -ResourceGroupName "testRG" -Name "testergw" -MinScaleUnits 3

ResourceGroupName   : testRG
Name                : testergw
Id                  : /subscriptions/{subscriptionId}/resourceGroups/testRG/providers/Microsoft.Network/expressRouteGateways/testergw
Location            : West US
MinScaleUnits       : 3
Type                : Microsoft.Network/expressRouteGateways
ProvisioningState   : Succeeded

Yukarıdakiler Azure'daki bu kaynak grubunda bir "testRG" kaynak grubu, bir Sanal WAN ve Batı ABD'de bir Sanal Merkez oluşturur. Bundan sonra Sanal Hub'da 2 ölçek birimiyle bir ExpressRoute ağ geçidi oluşturulur ve bu ağ geçidi 3 ölçek birimine değiştirilir.

Örnek 2: Bu ağ geçidini Sanal Wan olmayan ağlardan gelen trafiği kabul etmek için yapılandırın.

Ağ geçidini alabilir, AllowNonVirtualWanTraffic özelliğini yapılandırabilir ve değişiklikleri ağ geçidine kaydedebilir veya yalnızca Set-AzExpressRouteGateway cmdlet'indeki anahtarı kullanabilirsiniz

# Option 1 - Retrieve the gateway object, configure it to allow traffic from VNets and persist those changes.  
$gateway = Get-AzExpressRouteGateway -ResourceGroupName "resourceGroup001" -Name "gateway001"
$gateway.AllowNonVirtualWanTraffic = $true
$gateway = Set-AzExpressRouteGateway -InputObject $gateway

# Option 2 - Use the cmdlet switch
Set-AzExpressRouteGateway -ResourceGroupName "resourceGroup001" -Name "gateway001" -AllowNonVirtualWanTraffic $true

Örnek 3: Bu ağ geçidini Sanal Wan olmayan ağlardan gelen trafiği engelleyecek şekilde yapılandırın.

Ağ geçidini alabilir, AllowNonVirtualWanTraffic özelliğini yapılandırabilir ve değişiklikleri ağ geçidine kaydedebilir veya yalnızca Set-AzExpressRouteGateway cmdlet'indeki anahtarı kullanabilirsiniz

# Option 1 - Retrieve the gateway object, configure it to block traffic from VNets and persist those changes.  
$gateway=Get-AzExpressRouteGateway -ResourceGroupName "resourceGroup001" -Name "gateway001"
$gateway.AllowNonVirtualWanTraffic = $false
$gateway = Set-AzExpressRouteGateway -InputObject $gateway

# Option 2 - Use the cmdlet switch
Set-AzExpressRouteGateway -ResourceGroupName "resourceGroup001" -Name "gateway001" -AllowNonVirtualWanTraffic $false

Parametreler

-AsJob

Cmdlet'i arka planda çalıştırma

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

-Confirm

Cmdlet'i çalıştırmadan önce sizden onay ister.

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

-DefaultProfile

Azure ile iletişim için kullanılan kimlik bilgileri, hesap, kiracı ve abonelik.

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

-InputObject

Güncelleştirilmesi gereken ExpressRouteGateway.

Type:PSExpressRouteGateway
Aliases:ExpressRouteGateway
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-MaxScaleUnits

Bu ExpressRouteGateway için en fazla ölçek birimi sayısı. Geçerli aralık > 2

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

-MinScaleUnits

Bu ExpressRouteGateway için en az ölçek birimi sayısı. Geçerli aralık > 2

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

-Name

Kaynak adı.

Type:String
Aliases:ResourceName, ExpressRouteGatewayName, GatewayName
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-ResourceGroupName

Güncelleştirilecek ExpressRouteGateway kaynak grubu adı.

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

-ResourceId

Güncelleştirilmesi gereken ExpressRouteGateway kimliği.

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

-Tag

Kaynak etiketlerini temsil eden bir karma tablo.

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

-WhatIf

Cmdlet çalıştırılıyorsa ne olacağını gösterir. Cmdlet çalıştırılmaz.

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

Girişler

PSVirtualHub

String

Çıkışlar

PSExpressRouteGateway