many topics , many users , tried to solve the problem of applying PCQ with web-proxy enabled , the problem was packet goes from proxy were not marked , finally i found this WIKI example by Valens :
i applied this example as it is , but with changes to Qtree in order to test the difference between the direct packet mark and the proxy packet mark , i tested this config with downloading a file of 5MB which was direct download , in the Qtree i found that the proxy rate reaches the MAX while the direct rate still as it is !!! somthing strange !!! it should be vise versa that was i expect … and here is the config i copied from WIKI and pictures in real time when that 5MB file was downloading :
yes , but also the proxy rule counts much higher than the download ..
but i read in your wiki that the 1st rule (mangle) is for non-HTTP and direct downloading and the second is for proxy , so does that mean the proxy rule includes ALL HTTP packets ?? even the file which is downloading from the internet and its not exist in the proxy , couse its HTTP downloading too?
I didn’t see any strange thing from your example.
Both rules are for client, not for proxy.
One rule is for direct connection, and the other is for down traffic through proxy.
You can not compare also the statistic in the winbox by downloding small file or several seconds test.
The refresh time of the statistic is (or more than) 1 second.
What I can see from your screen capture is:
That time, the direct traffic is small, the traffic via proxy was big.
And this doesn’t mean that the condition was strange.
wht do you mean by through Proxy ?? it was supposed to be traffic from the cache drive , that was the problem before that some topics said that its impossible to mark … i also repeated the test with 100MB file and its the same , do you mean that any file downloading must pass through the proxy ??
The rule #2 will queueing direct traffic from internet to the client. If you set the proxy transparantly, you should test this rule using non http tcp port 80 traffic.
The rule #3 will queueing the traffic from proxy to the client. In previous reply, I said “traffic via proxy”, yes, it’s only the simple word… the content actually coming from internet, requested by proxy, and send to the client. So, this is not queueing the traffic from internet to the proxy, but from proxy to the client.
I look again your test, and still don’t get which one goes wrong. If you set transparant proxy (I guess you do so), and you test the script by downloading file via HTTP TCP port 80… off course only one rule will efect. If you want to test the other rule, try to do direct traffic, e.g. FTP or bandwidth test.
I see many people said it’s impossible to mark traffic from proxy to the client. But, CMIIW, I think it’s possible. I try to test it my self, and I wrote the how to in the wiki. If you also think it’s impossible… why you think so? IP flow system used by Mikrotik is quite complete… you can mark almost any packet.