Set-NetVirtualizationLookupRecord

Set-NetVirtualizationLookupRecord

Changes settings for policy entries that belong to a virtual network.

Syntax

Parameter Set: ByName
Set-NetVirtualizationLookupRecord [-AsJob] [-CimSession <CimSession[]> ] [-Context <String> ] [-CustomerAddress <String[]> ] [-CustomerID <String> ] [-MACAddress <String[]> ] [-PassThru] [-ProviderAddress <String> ] [-Rule <RuleType> ] [-ThrottleLimit <Int32> ] [-UseVmMACAddress <Boolean> ] [-VirtualSubnetID <UInt32[]> ] [-VMName <String> ] [ <CommonParameters>]

Parameter Set: InputObject (cdxml)
Set-NetVirtualizationLookupRecord -InputObject <CimInstance[]> [-AsJob] [-CimSession <CimSession[]> ] [-Context <String> ] [-CustomerID <String> ] [-PassThru] [-ProviderAddress <String> ] [-Rule <RuleType> ] [-ThrottleLimit <Int32> ] [-UseVmMACAddress <Boolean> ] [-VMName <String> ] [ <CommonParameters>]

Detailed Description

The Set-NetVirtualizationLookupRecord cmdlet changes settings for lookup record policy entries for IP addresses that belong to a virtual network. Network Virtualization allows more than one virtual network to exist on the same physical network. Computers can exchange network traffic with a virtual machine (VM) by using a Customer Address within the virtual network. Network Virtualization manages the Provider Addresses that are the physical network addresses. This cmdlet modifies records that map a Customer Address to a Provider Address. For more information, see Network Virtualization technical details (https://technet.microsoft.com/library/jj134174.aspx) on TechNet.

You can update the Provider Address, customer ID, context, VM name, and whether to use a VM media access control (MAC) address. You can specify which policy entries to update by using a Customer Address, a MAC address, a rule type, or a virtual subnet ID, or you can use the Get-NetVirtualizationLookupRecord cmdlet to obtain a policy entry.

Parameters

-AsJob

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-CimSession<CimSession[]>

Runs the cmdlet in a remote session or on a remote computer. Enter a computer name or a session object, such as the output of a New-CimSession or Get-CimSession cmdlet. The default is the current session on the local computer.

Aliases

Session

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Context<String>

Specifies a comment regarding the policy entry. Administrators can use this comment for any purpose.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-CustomerAddress<String[]>

Specifies an array of IP addresses within the Customer Address network. You can use both IPv4 and IPv6 addresses.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

true

-CustomerID<String>

Specifies an ID for a policy entry or VM. Administrators can use this setting for any purpose.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-InputObject<CimInstance[]>

Specifies the input to this cmdlet. You can use this parameter, or you can pipe the input to this cmdlet.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-MACAddress<String[]>

Specifies a MAC address that corresponds to the Customer Address.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

true

-PassThru

Returns an object representing the item with which you are working. By default, this cmdlet does not generate any output.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ProviderAddress<String>

Specifies an IP address, either IPv4 or IPv6, for a physical address that corresponds to the Customer Address.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Rule<RuleType>

Specifies which type of virtualization mechanism that the policy entry uses. The acceptable values for this parameter are:

-- TranslationMethodNat. IP address rewrite.
-- TranslationMethodEncap. Network Virtualization Generic Routing Encapsulation (NVGRE).
-- TranslationMethodNone. None.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ThrottleLimit<Int32>

Specifies the maximum number of concurrent operations that can be established to run the cmdlet. If this parameter is omitted or a value of 0 is entered, then Windows PowerShell® calculates an optimum throttle limit for the cmdlet based on the number of CIM cmdlets that are running on the computer. The throttle limit applies only to the current cmdlet, not to the session or to the computer.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-UseVmMACAddress<Boolean>

Indicates whether this entry uses its defined MAC address instead of physical MAC address. Virtual networking can use different MAC addresses for different VMs to balance traffic among multiple CPU cores.

A value of $True is only valid if the Rule parameter has a value of TranslationMethodNat. The default value for this setting is $False.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VirtualSubnetID<UInt32[]>

Specifies an array of IDs for virtual subnets that Customer Addresses belongs to. The acceptable values for this parameter are:integers from 4096 through 16777214.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VMName<String>

Specifies a name for the VM for this policy entry. Administrators can use this name for any purpose.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

Examples

Example 1: Change context and customer ID

This command uses the Get-NetVirtualizationLookupRecord cmdlet to get all the entries with a virtual subnet ID of 10000 and uses the pipe operator to pass them to the Set-NetVirtualizationLookupRecord cmdlet. This cmdlet changes the context to a descriptive phrase and changes the customer ID to a specified string.

PS C:\> Get-NetVirtualizationLookupRecord -VirtualSubnetID 10000 | Set-NetVirtualizationLookupRecord -Context "BlueCustomer Subnet1" -CustomerID "{00000000-0000-0000-0000-000000001234}"

Example 2: Change Provider Address and virtual subnet ID

This command makes changes for the entry that has the Customer Address 10.0.22.1. It sets the physical address to 172.23.1.1.

PS C:\> Set-NetVirtualizationLookupRecord -CustomerAddress "10.0.22.1" -ProviderAddress "172.23.1.1" 

Get-NetVirtualizationLookupRecord

New-NetVirtualizationLookupRecord

Remove-NetVirtualizationLookupRecord