Disabling Accelerated Networking on Azure

This a thing that I had to do in the past, first, not all VM size support Accelerated Network, the supported OS and VM size can be found here:

https://docs.microsoft.com/en-us/azure/virtual-network/create-vm-accelerated-networking-cli

https://docs.microsoft.com/en-us/azure/virtual-network/create-vm-accelerated-networking-powershell

In order to make the change I had to so deallocate the VM and execute the following PowerShell:

$nic = Get-AzureRmNetworkInterface -ResourceGroupName "RGName" -Name "VMName"
$nic.EnableAcceleratedNetworking = $false
$nic | Set-AzureRmNetworkInterface

Once I did this, I was able to change the size of the VM.

And of course, if you want to change the state of accelerated networking in a scale set, the procedure is slightly different:

Stop-AzVmss -ResourceGroupName "RG-name" -VMScaleSetName "vmss-name"
$vmss = Get-AzVmss -ResourceGroupName "RGName" -VMScaleSetName "vmss-name"
$vmss.VirtualMachineProfile.NetworkProfile.NetworkInterfaceConfigurations[0].EnableAcceleratedNetworking = $false
Update-AzVmss -ResourceGroupName "RGName" `
    -VMScaleSetName "vmss-name" `
    -VirtualMachineScaleSet $vmss

I changed the size of the VM Scale Set and then…

Start-AzVmss -ResourceGroupName "RGname" -VMScaleSetName "vmss-name"

 
That’s all

Advertisement

One thought on “Disabling Accelerated Networking on Azure

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s