Udostępnij za pośrednictwem


Update-AzureRmVpnSite

Aktualizacje lokacji VpnSite reprezentującej gałąź klienta do zamierzonego stanu celu.

Ostrzeżenie

Moduł AzureRM PowerShell został oficjalnie przestarzały od 29 lutego 2024 r. Zaleca się migrowanie użytkowników z modułu AzureRM do modułu Az programu PowerShell w celu zapewnienia ciągłej obsługi i aktualizacji.

Mimo że moduł AzureRM może nadal działać, nie jest już utrzymywany ani obsługiwany, umieszczając wszelkie dalsze zastosowania według uznania i ryzyka użytkownika. Zapoznaj się z naszymi zasobami migracji, aby uzyskać wskazówki dotyczące przejścia do modułu Az.

Składnia

Update-AzureRmVpnSite
      -ResourceGroupName <String>
      -Name <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -ResourceGroupName <String>
      -Name <String>
      -VirtualWanResourceGroupName <String>
      -VirtualWanName <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -ResourceGroupName <String>
      -Name <String>
      -VirtualWanId <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -ResourceGroupName <String>
      -Name <String>
      -VirtualWan <PSVirtualWan>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -InputObject <PSVpnSite>
      -VirtualWanResourceGroupName <String>
      -VirtualWanName <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -InputObject <PSVpnSite>
      -VirtualWanId <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -InputObject <PSVpnSite>
      -VirtualWan <PSVirtualWan>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -InputObject <PSVpnSite>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -ResourceId <String>
      -VirtualWanResourceGroupName <String>
      -VirtualWanName <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -ResourceId <String>
      -VirtualWanId <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -ResourceId <String>
      -VirtualWan <PSVirtualWan>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Update-AzureRmVpnSite
      -ResourceId <String>
      [-IpAddress <String>]
      [-AddressSpace <System.Collections.Generic.List`1[System.String]>]
      [-DeviceModel <String>]
      [-DeviceVendor <String>]
      [-LinkSpeedInMbps <UInt32>]
      [-BgpAsn <UInt32>]
      [-BgpPeeringAddress <String>]
      [-BgpPeeringWeight <UInt32>]
      [-Tag <Hashtable>]
      [-AsJob]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]

Opis

Aktualizacje lokacji VpnSite reprezentującej gałąź klienta do zamierzonego stanu celu.

Przykłady

Przykład 1

PS C:\> New-AzureRmResourceGroup -Location "West US" -Name "testRG"
PS C:\> $virtualWan = New-AzureRmVirtualWan -ResourceGroupName testRG -Name myVirtualWAN -Location "West US"
PS C:\> $vpnSiteAddressSpaces = New-Object string[] 2
PS C:\> $vpnSiteAddressSpaces[0] = "192.168.2.0/24"
PS C:\> $vpnSiteAddressSpaces[1] = "192.168.3.0/24"
PS C:\> New-AzureRmVpnSite -ResourceGroupName "testRG" -Name "testVpnSite" -Location "West US" -VirtualWan $virtualWan -IpAddress "1.2.3.4" -AddressSpace $vpnSiteAddressSpaces -DeviceModel "SomeDevice" -DeviceVendor "SomeDeviceVendor" -LinkSpeedInMbps "10"
PS C:\> New-AzureRmVpnSite -ResourceGroupName "testRG" -Name "testVpnSite" -Location "West US" -VirtualWan $virtualWan -IpAddress "2.3.5.5"

ResourceGroupName : testRG
Name              : testVpnSite
Id                : /subscriptions/{subscriptionId}/resourceGroups/testRG/providers/Microsoft.Network/vpnSites/testVpnSite
Location          : eastus2euap
IpAddress         : 2.3.4.5
VirtualWan        : /subscriptions/{subscriptionId}/resourceGroups/testRG/providers/Microsoft.Network/virtualWans/myVirtualWAN
AddressSpace      : {192.168.2.0/24, 192.168.3.0/24}
BgpSettings       :
Type              : Microsoft.Network/vpnSites
ProvisioningState : Succeeded

Powyższe polecenie utworzy grupę zasobów Virtual WAN w regionie Zachodnie stany USA w grupie zasobów "testRG" na platformie Azure.

Następnie tworzy witrynę VpnSite reprezentującą gałąź klienta i łącząc ją z wirtualną siecią WAN.

Po utworzeniu witryny zaktualizuje adres IpAddress witryny przy użyciu polecenia Set-AzureRmVpnSite.

Parametry

-AddressSpace

Prefiksy adresów sieci wirtualnej. Użyj tego obiektu lub obiektu AddressSpaceObject, ale nie obu tych obiektów.

Typ:List<T>[String]
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-AsJob

Uruchamianie polecenia cmdlet w tle

Typ:SwitchParameter
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-BgpAsn

Nazwa ASN protokołu BGP dla tej lokacji vpnSite.

Typ:UInt32
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-BgpPeeringAddress

Adres komunikacji równorzędnej protokołu BGP dla tej lokacji vpnSite.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-BgpPeeringWeight

Waga komunikacji równorzędnej BGP dla tej witryny VpnSite.

Typ:UInt32
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-Confirm

Monituje o potwierdzenie przed uruchomieniem polecenia cmdlet.

Typ:SwitchParameter
Aliasy:cf
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-DefaultProfile

Poświadczenia, konto, dzierżawa i subskrypcja używane do komunikacji z platformą Azure.

Typ:IAzureContextContainer
Aliasy:AzureRmContext, AzureCredential
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-DeviceModel

Model urządzenia zdalnego urządzenia sieci VPN.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-DeviceVendor

Dostawca urządzenia zdalnego urządzenia sieci VPN.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-InputObject

Obiekt lokacji sieci VPN, który ma zostać zmodyfikowany

Typ:PSVpnSite
Aliasy:VpnSite
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:True
Akceptowanie symboli wieloznacznych:False

-IpAddress

Adres IP bramy sieci lokalnej.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-LinkSpeedInMbps

Model urządzenia zdalnego urządzenia sieci VPN.

Typ:UInt32
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-Name

Nazwa zasobu.

Typ:String
Aliasy:ResourceName, VpnSiteName
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-ResourceGroupName

Nazwa grupy zasobów.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-ResourceId

Identyfikator zasobu platformy Azure dla witryny sieci VPN.

Typ:String
Aliasy:VpnSiteId
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:True
Akceptowanie symboli wieloznacznych:False

-Tag

Tabela skrótu reprezentująca tagi zasobów.

Typ:Hashtable
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-VirtualWan

Sieć VirtualWan, z tą witryną VpnSite musi być połączona.

Typ:PSVirtualWan
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-VirtualWanId

Element ResourceId VirtualWan musi być połączony z tą witryną VpnSite.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-VirtualWanName

Nazwa wirtualnej sieci VpnSite musi być połączona z.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-VirtualWanResourceGroupName

Nazwa grupy zasobów usługi VirtualWan, z tą lokacją vpnSite musi być połączona.

Typ:String
Position:Named
Domyślna wartość:None
Wymagane:True
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

-WhatIf

Pokazuje, co się stanie po uruchomieniu polecenia cmdlet. Polecenie cmdlet nie zostało uruchomione.

Typ:SwitchParameter
Aliasy:wi
Position:Named
Domyślna wartość:None
Wymagane:False
Akceptowanie danych wejściowych potoku:False
Akceptowanie symboli wieloznacznych:False

Dane wejściowe

PSVpnSite

String

Dane wyjściowe

PSVpnSite