Delen via


New-AzNetworkCloudNetworkAttachmentObject

Maak een in-memory object voor NetworkAttachment.

Syntaxis

New-AzNetworkCloudNetworkAttachmentObject
   -AttachedNetworkId <String>
   -IPAllocationMethod <VirtualMachineIPAllocationMethod>
   [-DefaultGateway <DefaultGateway>]
   [-Ipv4Address <String>]
   [-Ipv6Address <String>]
   [-Name <String>]
   [<CommonParameters>]

Description

Maak een in-memory object voor NetworkAttachment.

Voorbeelden

Voorbeeld 1: Maak een in-memory object voor NetworkAttachment.

New-AzNetworkCloudNetworkAttachmentObject -AttachedNetworkId "/subscriptions/subscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/l3Networks/l3NetworkName" -IPAllocationMethod "Dynamic" -DefaultGateway "True" -Ipv4Address "198.51.100.1" -Ipv6Address "2001:0db8:0000:0000:0000:0000:0000:0001" -Name "netAttachName01"

AttachedNetworkId                                                                                                        DefaultGateway IPAllocationMethod Ipv4Address  Ipv6Address
-----------------                                                                                                        -------------- ------------------ -----------  -----------                   
/subscriptions/subscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/l3Networks/l3NetworkName True           Dynamic            198.51.100.1 2001:0db8:0000:0000:0000:0000…

Maak een in-memory object voor NetworkAttachment.

Parameters

-AttachedNetworkId

De resource-id van het gekoppelde netwerk dat is gekoppeld aan de virtuele machine. Het kan een van cloudServicesNetwork-, l3Network-, l2Network- of trunkedNetwork-resources zijn.

Type:String
Position:Named
Default value:None
Vereist:True
Pijplijninvoer accepteren:False
Jokertekens accepteren:False

-DefaultGateway

De indicator of dit de standaardgateway is. Slechts één van de gekoppelde netwerken (inclusief de CloudServicesNetwork-bijlage) voor één computer kan worden opgegeven als Waar.

Type:DefaultGateway
Position:Named
Default value:None
Vereist:False
Pijplijninvoer accepteren:False
Jokertekens accepteren:False

-IPAllocationMethod

Het IP-toewijzingsmechanisme voor de virtuele machine. Dynamisch en Statisch zijn alleen geldig voor l3Network, die ook Uitgeschakeld kan opgeven. Anders is Uitgeschakeld de enige toegestane waarde.

Type:VirtualMachineIPAllocationMethod
Position:Named
Default value:None
Vereist:True
Pijplijninvoer accepteren:False
Jokertekens accepteren:False

-Ipv4Address

Het IPv4-adres van de virtuele machine.

    This field is used only if the attached network has IPAllocationType of IPV4 or DualStack.

    If IPAllocationMethod is:
    Static - this field must contain a user specified IPv4 address from within the subnet specified in the attached network.
    Dynamic - this field is read-only, but will be populated with an address from within the subnet specified in the attached network.
    Disabled - this field will be empty.
Type:String
Position:Named
Default value:None
Vereist:False
Pijplijninvoer accepteren:False
Jokertekens accepteren:False

-Ipv6Address

Het IPv6-adres van de virtuele machine.

    This field is used only if the attached network has IPAllocationType of IPV6 or DualStack.

    If IPAllocationMethod is:
    Static - this field must contain an IPv6 address range from within the range specified in the attached network.
    Dynamic - this field is read-only, but will be populated with an range from within the subnet specified in the attached network.
    Disabled - this field will be empty.
Type:String
Position:Named
Default value:None
Vereist:False
Pijplijninvoer accepteren:False
Jokertekens accepteren:False

-Name

De interfacenaam van het gekoppelde netwerk. Indien opgegeven, heeft de naam van de netwerkbijlage een maximale lengte van 15 tekens en moet deze uniek zijn voor deze virtuele machine. Als de gebruiker deze waarde niet opgeeft, wordt de standaardinterfacenaam van de netwerkresource gebruikt. Voor een CloudServicesNetwork-resource wordt deze naam genegeerd.

Type:String
Position:Named
Default value:None
Vereist:False
Pijplijninvoer accepteren:False
Jokertekens accepteren:False

Uitvoerwaarden

NetworkAttachment