How to Configure Priority Flow Control (PFC) on Windows 11 Using PowerShell

In high-throughput enterprise networking, storage fabrics such as RoCEv2 (RDMA over Converged Ethernet) and Storage Spaces Direct (S2D) require a lossless network transport layer. Traditional IEEE 802.3x link-level Flow Control pauses an entire physical link when buffer thresholds are exceeded, halting all network traffic indiscriminately. To prevent packet loss without stalling latency-sensitive control or bulk traffic, IEEE 802.1Qbb Priority-based Flow Control (PFC) operates at Layer 2 across individual IEEE 802.1p traffic priority classes. Windows 11 includes full native support for Data Center Bridging (DCB) and PFC via the PowerShell Network Quality of Service (NetQoS) module.

Understanding Priority-based Flow Control (PFC) and DCB

Priority-based Flow Control divides Ethernet traffic traversing a single physical link into eight distinct virtual lanes or priority levels (numbered 0 through 7). When congestion occurs on a specific priority queue\u2014such as priority 3, commonly reserved for RoCEv2 traffic\u2014the receiving switch or network adapter transmits a PAUSE frame specifically targeted to that priority class. The sender pauses transmission only for that priority level while other classes (such as standard TCP web traffic on priority 0) continue flowing uninterrupted.

Configuring PFC on Windows 11 requires three core components:

  • DCB Feature Activation: Enabling the Data Center Bridging Windows feature.
  • Flow Control Settings: Designating specific 802.1p priorities as lossless (flow control enabled).
  • QoS Policy Definition: Mapping specific protocol ports or applications to designated traffic classes.

Enabling the Data Center Bridging Feature

The NetQoS cmdlets responsible for configuring PFC rely on the Data Center Bridging component. Open PowerShell with administrative privileges and verify whether Data Center Bridging is installed:

Get-WindowsOptionalFeature -Online -FeatureName DataCenterBridging

If the state is disabled, install the feature:

Enable-WindowsOptionalFeature -Online -FeatureName DataCenterBridging -NoRestart

Once enabled, the NetQos PowerShell module cmdlets become available for configuring policy maps, priority flow control, and transmission selectors.

Verifying Network Adapter PFC Capability

Before configuring policies, ensure your physical network interface card (NIC) supports hardware Data Center Bridging:

Get-NetAdapterQos

The command lists active network interfaces along with their hardware QoS and DCB status. To inspect specific flow control capabilities for a specific adapter:

Get-NetAdapterQos -Name "Ethernet 1" | Format-List HardwareCapabilities

Verify that PriorityFlowControlSupported returns True.

Configuring Priority Flow Control for Lossless Classes

By default, Windows operating systems disable PFC across all priorities. To designate Priority 3 as lossless (the standard assignment for RDMA and RoCEv2 traffic):

Enable-NetQosFlowControl -Priority 3

If you also require lossless transport for a secondary traffic class (such as cluster heartbeat communication on Priority 5):

Enable-NetQosFlowControl -Priority 3,5

To inspect active priority flow control settings across all priorities:

Get-NetQosFlowControl

The output displays the enabled/disabled status for each of the eight priorities (0 to 7):

Priority Enabled
-------- -------
0        False
1        False
2        False
3        True
4        False
5        True
6        False
7        False

Creating a NetQoS Policy to Tag Traffic

Enabling PFC on a priority level only pauses frames tagged with that 802.1p priority tag. To instruct Windows to tag specific network traffic with Priority 3, create a NetQoS policy:

New-NetQosPolicy -Name "RoCEv2-Traffic" -NetDirectPort 445 -PriorityValue8021Action 3

For custom UDP or TCP applications requiring lossless flow control:

New-NetQosPolicy -Name "Storage-Replication" -IPProtocol UDP -IPDstPort 4791 -PriorityValue8021Action 3

This rule ensures that UDP packets transmitted to port 4791 receive Layer 2 802.1p priority tag 3 and DSCP tag 26, matching the lossless queue.

Enabling DCB and PFC on the Physical Adapter

Once global NetQoS policies are defined, bind Data Center Bridging directly to the physical interface:

Enable-NetAdapterQos -Name "Ethernet 1"

To verify operational flow control parameters on the adapter:

Get-NetAdapterQos -Name "Ethernet 1" | Select-Object -ExpandProperty OperationalFlowControl

The output confirms whether the adapter is actively enforcing PFC on the requested priorities:

Priority Enabled
-------- -------
3        True
5        True

Resetting and Removing Priority Flow Control Configurations

If you need to revert changes or return the network adapter to standard best-effort Ethernet transport, disable flow control on the designated priorities:

Disable-NetQosFlowControl -Priority 3,5

Remove any custom NetQoS policies:

Remove-NetQosPolicy -Name "RoCEv2-Traffic" -Confirm:$false
Remove-NetQosPolicy -Name "Storage-Replication" -Confirm:$false

Finally, disable QoS enforcement on the physical network adapter:

Disable-NetAdapterQos -Name "Ethernet 1"

The adapter returns to default non-DCB operation without requiring an operating system reboot.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.