Windows 7 QoS policy - based on time of day?

Dave Trouser

Honorable
Sep 21, 2013
12
0
10,510
As the subject suggests, I want to vary my QoS policies on my server according to the time of day. The reason is that I am using Virgin Media as my ISP, and they have a traffic management policy. I am mirroring a large amount of data to Bitcasa (over 2TB), and need that to happen as fast as possible without triggering the rate caps.
At the moment, I have bitcasa limited to 160Kbps, which is a safe speed to run 24/7 without triggering the rate caps and still allows normal use on top, but obviously progress is slow at this rate.
What I really would like, is to automatically change the QoS policy between 1am and 5am so that Bitcasa has no limits applied. I cannot see a way of doing this in the QoS policy editor, and it's looking like some sort of scheduled script may be in order, but I thought I'd ask in case there is a "proper" way of doing this. Google reveals nothing for Windows - only high-end routers from Cisco etc.
There is no scheduled QoS on my router either (though it respects QoS tagging), so that isn't an option.
 
I am sure you can do this in a windows server......one of our server experts here likely knows. It is best if you can do it on the machine before the traffic leaves.

You might be able to do it with a stock asus router. I am not sure if it has time of day but it clearly has the ability to put hard rate limits on traffic.
DD_WRT of course can do it since it has the same hard type rate limits and you can run cron jobs since it is a unix platform. There are example of how to change policy based on time of day on the dd-wrt site.

Now I am assuming this is outbound ie upload traffic it tends to be very tricky to try to limit download traffic on the receiving side.

 
Yeah, it is outgoing traffic, and ideally I do want the QoS tagging done on the machine rather than router, as my switches are all QoS aware. I still haven't found a way that's built in to Windows.

It's looking like some sort of bespoke arrangement of Powershell and scheduled tasks may be the way forward.
 
The actual tagging of packets is a waste of time mostly. All this does is identify traffic. You would still need all the traffic limitation stuff in the router. You are now just matching a packet tag rather than a IP address or a port number or something. The selection of the traffic is the easy part it it actually applying the limits that would require the special router software.

I am not sure it is on all versions of windows but it appears microsoft removes any form of packet markings on the client versions of their OS. You can set the tags and the sniffer will actually show the tags but what comes out the port does not have tags. You normally have to set the tags with a group policy which only sets the tag to a fixed value by process name it does not allow the process to set the tags themselves.

There are software packages that run quota that I have seen used for satellite I just don't remember if it can do time of day. The down site of client based is they have no knowledge of what other clients are doing.
 
My router (ASUS RT-N56U, running the latest WRT based firmware) does support and respect packet tagging, as do my two smart switches, so tagging is not wasted here. I do in fact want manual tagging - so I can enforce not only the bitrate, but priority of Bitcasa packets. It does work very well, and this is best done before the packets leave the machine so that all the router has to do is packet scheduling and not rate limiting. In this way, Bitcasa can never interfere with the smooth running of Plex Media Server/Home Theatre, as Plex has an enforced DSCP value of 50, while Bitcasa (and all my other cloud services) has a value of 4.

Windows 7 Pro and above support marking of packets, but what most people don't know is that this is disabled by default (unlike Vista and XP), and any changes made in the group policy editor (or local policy editor) have zero effect until a registry change is made, thus:

HKEY_LOCAL_MACHINE\Software\Microsoft\RTC\Transport\QoSEnabled - set DWORD to "1". Without that, the policy does nothing and no packets are tagged - everything is "best effort".

Anyway, this is getting a little off topic... I suppose I could schedule a very basic script that toggles "QoSEnabled" at the relevant times, but if I can avoid that it'd be nicer. I was hoping there was some hidden way of scheduling policies - pure wishful thinking! 🙂