Set-VBRViNetworkMappingRule

In this article

    Short Description

    Modifies network mapping rules of isolated networks.

    Applies to

    Product Edition: Standard, Enterprise, Enterprise Plus, Veeam Universal License

    Syntax

    Set-VBRViNetworkMappingRule [-NetworkMapping <VBRViVirtualLabNetworkMappingRule>] [-ProductionNetwork <VBRViNetworkInfo>] [-IsolatedNetworkName <string>] [-VLANID <int>]  [<CommonParameters>]

    Detailed Description

    This cmdlet modifies network mapping rules of isolated networks.

    Parameters

    Parameter

    Description

    Type

    Required

    Position

    Accept Pipeline Input

    NetworkMapping

    Specifies the network mapping rule of isolated networks. The cmdlet will modify settings of this network mapping rule.

    Accepts the VBRViVirtualLabNetworkMappingRule object. To create this object, run the New-VBRViNetworkMappingRule cmdlet.

    False

    Named

    False

    ProductionNetwork

    Specifies a production network with original VMs. The cmdlet will map VMs from this network to VMs from the isolated network.

    Accepts the VBRViNetworkInfo object. To get this object, run the Get-VBRViServerNetworkInfo cmdlet.

    False

    Named

    False

    IsolatedNetworkName

    Specifies a name of an isolated network. The cmdlet will create an isolated network with this name.

    String

    False

    Named

    False

    VLANID

    Specifies an ID of an isolated network. The cmdlet will create the isolated network with the specified ID.

    Int32

    False

    Named

    False

    <CommonParameters>

    This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About CommonParameters section of Microsoft Docs.

    Output Object

    The cmdlet returns the VBRViVirtualLabNetworkMappingRule object that defines network mapping rules of isolated networks.

    Examples

    Set-VBRViNetworkMappingRuleExample 1. Modifying Mapping to Production Network

    This example shows how to modify mapping rule and to map an isolated network to another production network.

    $server = Get-VBRServer -Name "srv01.veeam.local"

    $production = Get-VBRViServerNetworkInfo -Server $server

    $isolated = New-VBRViNetworkMappingRule -ProductionNetwork $production[3] -IsolatedNetworkName "Sandbox01 Private VM Network" -VLANID 5

    New-VBRViNetworkMappingRule -NetworkMapping $isolated -ProductionNetwork $production[7]

    Perform the following steps:

    1. Run the Get-VBRServer cmdlet. Specify the Name parameter value. Save the result to the $server variable.
    2. Run the Get-VBRViServerNetworkInfo cmdlet. Set the $server variable as the Server parameter value. Save the result to the $network variable.
    3. Run the New-VBRViNetworkMappingRule cmdlet. Specify the necessary parameters. Save the result to the $isolated variable.
    1. Run the Set-VBRViNetworkMappingRule cmdlet. Set the $isolated variable as the NetworkMapping parameter value. Set the $production[7] as the ProductionNetwork parameter value.

    The Get-VBRViServerNetworkInfo cmdlet will return an array of production networks. Mind the ordinal number of the necessary production network (An array starts with 0. In our example, it is the sixth production network in the array).

    Set-VBRViNetworkMappingRuleExample 2. Modifying Isolated Network Name and ID

    This example shows how to modify a name and ID of an isolated network.

    $server = Get-VBRServer -Name "srv01.veeam.local"

    $production = Get-VBRViServerNetworkInfo -Server $server

    $isolated = New-VBRViNetworkMappingRule -ProductionNetwork $production[3] -IsolatedNetworkName "Sandbox01 Private VM Network" -VLANID 5

    Set-VBRViNetworkMappingRule -NetworkMapping $isolated -IsolatedNetworkName "Sandbox07 Private VM Network" -VLANID

    Perform the following steps:

    1. Run the Get-VBRServer cmdlet. Specify the Name parameter value. Save the result to the $server variable.
    2. Run the Get-VBRViServerNetworkInfo cmdlet. Set the $server variable as the Server parameter value. Save the result to the $network variable.
    3. Run the New-VBRViNetworkMappingRule cmdlet. Specify the necessary parameters. Save the result to the $isolated variable.
    1. Run the Set-VBRViNetworkMappingRule cmdlet. Specify the following settings:
    • Set the $isolated variable as the NetworkMapping parameter value.
    • Specify the IsolatedNetworkName parameter value.
    • Specify the VLANID parameter value.

    Related Commands