#PStip Enabling RSS inside Hyper-V guest OS

Note: This tip requires PowerShell 3.0 or above.

While reviewing results returned by the Best Practices Analyzer on a virtual machine, a warning about RSS (Receive Side Scaling) was raised.

RSS has been around since Windows 2008. The online help states:

“RSS is a scalability technology that distributes the receive network traffic among multiple processors by hashing the header of the incoming packet. Without RSS in Windows Server® 2008 and later, network traffic is received on the first processor which can quickly reach full utilization limiting receive network throughput.”

It’s a nice surprise–RSS has now been extended to Windows Server 2012 R2 Hyper-V. The guest virtual machine can now use this functionality. To check whether my virtual network adapter was really RSS capable, I used the Get-SmbClientNetworkInterface cmdlet:

Get-SmbClientNetworkInterface |
Format-Table -Property FriendlyName,RssCapable -AutoSize

To determine how the virtual network adapter was currently configured:

Get-NetAdapter | Where Status -eq "Up" |
Get-NetAdapterAdvancedProperty -DisplayName "Receive Side Scaling" |
Format-Table -AutoSize

To turn on RSS on the RSS-capable virtual network adapter:

Get-NetAdapter | Where Status -eq "Up" |
Get-NetAdapterAdvancedProperty -DisplayName "Receive Side Scaling" |
Where DisplayValue -eq "Disabled" |
Enable-NetAdapterRss -Verbose

Note that you can add –NoRestart switch to the Enable-NetAdapterRss  cmdlet to avoid the network adapter from being restarted immediately.

Share on: