Enabling IP forwarding using Azure PowerShell

Enabling IP forwarding using PowerShell has a gotcha, as you cannot enable it for an NIC by using the cmdlets we have already looked at.

Instead, you have to ensure that the NIC for which you want to enable IP forwarding is stored in a variable such as $NIC.

Then, you can run the following cmdlet:

$NIC.EnableIPForwarding = 1

Finally, you can save your configuration by running the following cmdlet:

$NIC | Set-AzureRmNetworkInterface
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset