Windows OS Hub
  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu
  • Home
  • About

Windows OS Hub

  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu

 Windows OS Hub / Windows 10 / Throttling Network File Transfer Speed on Windows

May 10, 2023 Windows 10Windows Server 2016

Throttling Network File Transfer Speed on Windows

In this article we’ll show you how to restrict network data transfer rate to/from Windows Server 2016 and Windows 10 using built-in and third-party tools. You may know that Windows apps use the most of the available network interface bandwidth by default. It may result in some issues if a task (mostly SMB shared network folders) use all available bandwidth of a network adapter. You can restrict the maximum file copy rate from a network shared folder, thus providing users of other apps with guaranteed network adapter resources.

To manage traffic classes or priorities in TCP/IP networks, QoS (Quality of Service) technology is used.

Contents:
  • Configuring QoS Group Policy on Windows
  • Managing Windows Network QoS Policies via PowerShell
  • Set-SmbBandwidthLimit: Configure SMB Bandwidth Limit with PowerShell
  • Throttling File Transfer Bandwidth in Robocopy
  • Traffic Shaping Using Third-Party Tools

Configuring QoS Group Policy on Windows

You can manage traffic priority in Windows using QoS GPO settings. In this scenario, I will restrict the data transfer rate for all outbound connections. (The policy will be applied even when users copy files from your server.) Using this example, you can restrict the rate for any app, port or host/site.

QoS Group Policies are supported in:

  • Windows Server 2008 or higher
  • Windows Vista or higher

First of all, check your network adapter settings to make sure that the Qos Packet Scheduler option is enabled.

enable Qos Packet Scheduler for your network connection

  1. Run the Local Group Policy Editor console (gpedit.msc), go to Computer Configuration -> Windows Settings -> Policy-based QoS and click Create new policy; Create new Policy-based QoS on Windows
  2. Specify the policy name, check the option Specify Outbound Throttle Rate and set the Throttle Rate. It is the rate in MBps/KBps you want to restrict the rate of outbound traffic to;
    Note. You can also set the DSCP value. DSCP (Differenciated Services Code Point) may be used on advanced routers like Cisco/Mikrotik. Depending on the DSCP value of a network packet, the routers will set the priority for it. Don’t use this option if you are unsure of the DSCP QoS settings on your routers.
    set outbound throttle rate with windows qos policy
  3. Then you may select a process/app (an executable file .exe) or an IIS http(s) site the policy will be applied to. I left All applications option checked;select applications to apply qos policy on windows
  4. You can specify the IP interface on your computer the policy will be applied to. You may need it if you have multiple network adapters or IP aliases;
  5. You can also set the destination IP address to restrict the transfer rate for it; qos policy - set source and destination IP addresses
  6. Then specify a protocol the policy will be applied to (TCP, UDP, or TCP and UDP). You can also select a source and a target port. If you are not sure what protocol your app is using, select TCP and UDP. If you want to restrict the access rate to shared files in the SMB folder, select TCP and Port 445. set protocol, source and destination ports in windows qos policy

QoS policy in Windows is configured. You don’t need to reboot your computer, the data transfer rate in the network will be shaped right after you apply the changes. Note that the Throttle Rate is displayed in kilobytes in the policy editor, even if you have selected MB as its value.

qos policy on windows

Since I have selected all apps and all ports, the policy throttles the maximum network file transfer rate to 3 MB (including file copy using File Explorer — explorer.exe). In the screenshot below, you can see that the configured QoS policy slow the network file transfer rate on Windows.

windows 10 slow file transfer over network

Also, there are Advanced QoS policies available only in the Computer Configuration Group Policy section. You can restrict the inbound TCP traffic in the Inbound TCP Traffic tab (the DSCP Marking Override tab refers to DSCP settings, we won’t discuss it here).

Inbound TCP Traffic throughput level

As you can see, there are 4 levels of traffic restriction. The following table shows the levels and their rates.

Inbound TCP throughput levelMaximum Transfer Rate
064 KB
1256 KB
21 MB
316 MB

Managing Windows Network QoS Policies via PowerShell

You can use PowerShell to create and manage network QoS policies. For example, to create a QoS policy that restrict the bandwidth for SMB (shared file) traffic, use the following command:

New-NetQosPolicy -Name "SMBRestrictFileCopySpeed" -SMB -ThrottleRateActionBitsPerSecond 10MB

Name : SMBRestrictFileCopySpeed
Owner : Group Policy (Machine)
NetworkProfile : All
Precedence : 127
Template : SMB
JobObject :
ThrottleRate : 10.486 MBits/sec

To display a list of applied QoS policies on a computer, run this command:
Get-NetQosPolicy

configure-qos-policy-on-windows-with-New-NetQosPolicy-powershell-cmdlet

To edit or remove a QoS policy, Set-NetQosPolicy and Remove-NetQosPolicy cmdlets are used.

Remove-NetQosPolicy -Name SMBRestrictFileCopySpeed

Set-SmbBandwidthLimit: Configure SMB Bandwidth Limit with PowerShell

The Set-SmbBandwidthLimit cmdlet allows to restrict the file transfer rate over the SMB protocol. First of all, install the Windows Server component SMB Bandwidth Limit using PowerShell:

Add-WindowsFeature -Name FS-SMBBW

Or you can install it from the graphical Server Manager (Add Windows Feature -> SMB Bandwidth Limit).

Usually this module is used to configure bandwidth limit for Hyper-V Live Migration. For example, the following command will restrict the maximum virtual machine migration speed to 100 MB/s.

Set-SmbBandwidthLimit -Category LiveMigration -BytesPerSecond 100MB

Set-SmbBandwidthLimit-powershell

You can also use the -Category Default parameter to restrict common file transfer traffic over SMB.

Set-SmbBandwidthLimit -Category Default -BytesPerSecond 10MB

FS-SMBBW is available in Windows Server 2012 R2 or higher.

Throttling File Transfer Bandwidth in Robocopy

When working with robocopy, you can also use a special parameter to limit the speed of copying/moving files over the network. It is /ipg (Inter packet Gap). The key sets a gap between packages in milliseconds and is used to reduce the network load when copying files over low-speed channels. Robocopy transmits data over a network in 64 KB blocks. Thus if you know the bandwidth of your network link, you can count the relevant /ipg value based on the transfer rate requirements.

If you don’t want to go deep into formulas, you can use a ready Robocopy IPG Calclator: http://www.zeda.nl/index.php/en/robocopyipgcalculator-en-2

robocopy ipg calculator

You can also use the BITS protocol to copy data to slow or unstable network links (see the example in the article on how to copy large files using BITS and PowerShell). The BITS protocol allows to dynamically manage the data transfer speed between two hosts depending on the channel load and supports download resuming.

Traffic Shaping Using Third-Party Tools

The most popular commercial solution to limit throughput in Windows depending on a port, app or destination is NetLimiter. The most popular free tool is TMeter Free.

It is also worth to mention:

  1. Glasswire – also includes a firewall and a network monitor;
  2. NetBalancer – network monitoring and setting traffic rules;
  3. cFosSpeed – can configure traffic priorities for apps;
  4. Net Peeker – like Glasswire, it has firewall features and may set traffic priorities.

Windows QoS policies can limit the data transfer rate in the network well, so if you want to do it, try QoS first of all. Like any other policy, you can configure them on the domain level with the gpmc.msc console.

Third-party software has more features and a graphical interface, but these apps are mostly commercial.

2 comments
0
Facebook Twitter Google + Pinterest
previous post
How to Rebuild (Reset) a Corrupted Icon Cache on Windows 10?
next post
How to Find Inactive Computers and Users in Active Directory with PowerShell?

Related Reading

How to Connect VPN Before Windows Logon

November 14, 2023

Using WPAD (Web Proxy Auto-Discovery Protocol) on Windows

November 7, 2023

Zabbix: How to Get Data from PowerShell Scripts

October 27, 2023

Tracking Printer Usage with Windows Event Viewer Logs

October 19, 2023

How to Use Ansible to Manage Windows Machines

September 25, 2023

2 comments

Lino April 30, 2021 - 7:17 pm

I use an alternative to Robocopy called Gs Richcopy 360, it has an option to throttle the connection while transferring to the clouds, it is really a very helpful tool

Reply
Dirk Gomez January 24, 2022 - 9:17 am

Thanks for this article and to LINO, I was searching for a solution to control the speed while syncing to Azure blob and Gs Richcopy 360 really did the job, keep going

Reply

Leave a Comment Cancel Reply

Categories

  • Active Directory
  • Group Policies
  • Exchange Server
  • Microsoft 365
  • Azure
  • Windows 11
  • Windows 10
  • Windows Server 2022
  • Windows Server 2019
  • Windows Server 2016
  • PowerShell
  • VMWare
  • Hyper-V
  • Linux
  • MS Office

Recent Posts

  • How to Connect VPN Before Windows Logon

    November 14, 2023
  • Removing Azure Arc Setup Feature on Windows Server 2022

    November 9, 2023
  • Using WPAD (Web Proxy Auto-Discovery Protocol) on Windows

    November 7, 2023
  • Send Emails with Microsoft Graph API and PowerShell

    November 6, 2023
  • Zabbix: How to Get Data from PowerShell Scripts

    October 27, 2023
  • Tracking Printer Usage with Windows Event Viewer Logs

    October 19, 2023
  • PowerShell: Configure Certificate-Based Authentication for Exchange Online (Azure)

    October 15, 2023
  • Reset Root Password in VMware ESXi

    October 12, 2023
  • How to Query and Change Teams User Presence Status with PowerShell

    October 8, 2023
  • How to Increase Size of Disk Partition in Ubuntu

    October 5, 2023

Follow us

  • Facebook
  • Twitter
  • Telegram
Popular Posts
  • How to Repair EFI/GPT Bootloader on Windows 10 or 11
  • How to Restore Deleted EFI System Partition in Windows
  • Network Computers are not Showing Up in Windows 10/11
  • Updating List of Trusted Root Certificates in Windows
  • How to Create a Wi-Fi Hotspot on your Windows PC
  • How to Sign an Unsigned Device Driver in Windows
  • How to Download APPX File from Microsoft Store for Offline Installation?
Footer Logo

@2014 - 2023 - Windows OS Hub. All about operating systems for sysadmins


Back To Top