Example Customized QoS

General questions.
bloater99
Posts: 482
Joined: October 13th, 2014, 3:47 pm

Re: Example Customized QoS

Post by bloater99 » September 28th, 2015, 4:19 pm

dnl,

Our conversation has inspired me to make an organizational change to my rules. Basically, I am combining icmp, dns and ntp together into Class 101/200 and using Class 102/202 for RTP, Skypetoskype, and gaming ports (such as 25565 for minecraft). So ping and dns got get top priority while realtime streaming and gaming get prioritized above web (my Class 3). Maximum bandwidth is capped pretty low since that's not needed for these protocols. They do get priority, which is what they do need, though.
Image

Image

dnl
Posts: 375
Joined: June 28th, 2013, 11:03 am

Re: Example Customized QoS

Post by dnl » September 29th, 2015, 11:01 am

Cool!

I've been looking around the internet for good usage examples of QoS, but keep finding Cisco-specific things which don't have any actual example usages, just the syntax for Cisco's IOS.



Anyway, if you're curious here's my current configuration in files.
Note that I've not included a VPN class yet and I've sadly got terrible "broadband" here:

/var/ipfire/qos/services (Note that I shifted ACK to the end of the 100-range classes, but have not changed its priority. I've also given each class the minimal guaranteed bandwidth I can without errors - this is something I plan to tweak later. It's annoying that I've got such a small upload bandwidth, but that's life. For now just having QoS priorities is adequate.)

Code: Select all

imq0;202;1;80;3000;;;8;Services (ping,DNS,NTP);
imq0;203;2;80;4970;;;8;IM & VoIP Downlink;
imq0;204;3;80;4970;;;4;Streaming Media Down;
imq0;205;4;80;4970;;;4;Web Downlink;
imq0;210;5;80;4970;;;0;Default Downlink;
imq0;211;6;80;4970;;;2;Email Downlink;
imq0;212;7;80;4970;;;2;File Transfer Downlink;
ppp0;102;1;80;900;;;8;Services (ping,DNS,NTP);
ppp0;103;2;80;930;;;8;IM & VoIP Uplink;
ppp0;104;3;80;930;;;4;Streaming Media Uplink;
ppp0;105;4;80;930;;;4;Web Uplink;
ppp0;110;5;80;930;;;0;Default Uplink;
ppp0;111;6;80;930;;;2;Email Uplink;
ppp0;112;7;80;930;;;1;File Transfer Uplink;
ppp0;115;1;80;900;;;8;ACK (special);
/var/ipfire/qos/portconfig (note the google ranges which seem to host youtube for me. I've not researched netflix yet)

Code: Select all

102;ppp0;icmp;;;;;
102;ppp0;tcp;;;;123;
102;ppp0;tcp;;;;53;
102;ppp0;udp;;;;123;
102;ppp0;udp;;;;53;
103;ppp0;tcp;;;;5004;
103;ppp0;tcp;;;;5060;
103;ppp0;tcp;;;;5061;
103;ppp0;tcp;;;;5228;
103;ppp0;tcp;;;;5229;
103;ppp0;tcp;;;;5230;
103;ppp0;udp;;;;5004;
103;ppp0;udp;;;;5060;
103;ppp0;udp;;;;5061;
104;ppp0;tcp;;;173.194.0.0/16;;
104;ppp0;tcp;;;216.58.192.0/19;;
104;ppp0;tcp;;;74.125.0.0/16;;
104;ppp0;tcp;;;;1935;
105;ppp0;tcp;;;;443;
105;ppp0;tcp;;;;80;
111;ppp0;tcp;;;;143;
111;ppp0;tcp;;;;465;
111;ppp0;tcp;;;;587;
111;ppp0;tcp;;;;993;
112;ppp0;tcp;;;;119;
112;ppp0;tcp;;;;152;
112;ppp0;tcp;;;;20;
112;ppp0;tcp;;;;21;
112;ppp0;tcp;;;;873;
112;ppp0;udp;;;;152;
112;ppp0;udp;;;;20;
202;imq0;icmp;;;;;
202;imq0;tcp;;123;;;
202;imq0;tcp;;53;;;
202;imq0;udp;;123;;;
202;imq0;udp;;53;;;
203;imq0;tcp;;5004;;;
203;imq0;tcp;;5028;;;
203;imq0;tcp;;5029;;;
203;imq0;tcp;;5030;;;
203;imq0;tcp;;5060;;;
203;imq0;tcp;;5061;;;
203;imq0;udp;;5004;;;
203;imq0;udp;;5060;;;
203;imq0;udp;;5061;;;
203;ppp0;dccp;;5004;;;
204;imq0;tcp;173.194.0.0/16;;;;
204;imq0;tcp;216.58.192.0/19;;;;
204;imq0;tcp;74.125.0.0/16;;;;
204;imq0;tcp;;1935;;;
205;imq0;tcp;;443;;;
205;imq0;tcp;;801;;;
205;imq0;tcp;;80;;;
211;imq0;tcp;;143;;;
211;imq0;tcp;;465;;;
211;imq0;tcp;;587;;;
211;imq0;tcp;;993;;;
212;imq0;tcp;;119;;;
212;imq0;tcp;;152;;;
212;imq0;tcp;;20;;;
212;imq0;tcp;;21;;;
212;imq0;udp;;152;;;
212;imq0;udp;;20;;;
212;imq0;udp;;873;;;
/var/ipfire/qos/level7config (The FTP filter refuses to work!!)

Code: Select all

112;ppp0;ftp;;;
212;ppp0;ftp;;;
203;imq0;skypetoskype;;;
103;ppp0;skypetoskype;;;
/var/ipfire/qos/tosconfig (I'm experimenting with this - I do get some packets with existing QoS tags, I'll have to do packet capture to determine what they're for)

Code: Select all

203;imq0;8;
204;imq0;4;
103;ppp0;8;
104;ppp0;4;

bloater99
Posts: 482
Joined: October 13th, 2014, 3:47 pm

Re: Example Customized QoS

Post by bloater99 » September 30th, 2015, 3:43 pm

dnl wrote:I've been looking around the internet for good usage examples of QoS, but keep finding Cisco-specific things which don't have any actual example usages, just the syntax for Cisco's IOS.
Yeah, me too. There is some QoS wisdom in the DD-WRT and Tomato firmware websites/forums that you might find useful with a little googling. I recall reading some posts from someone who uses QoS on an old Linksys WRT54GL with an open source firmware to provide service to a large apartment complex. He claims excellent performance with many dozens of users with his methodology.
Image

Image

apexcomputers
Posts: 28
Joined: March 20th, 2015, 1:50 pm
Location: Busselton, Western Australia

Re: Example Customized QoS

Post by apexcomputers » December 28th, 2015, 6:34 am

bloater99 any chance of getting the code from your QoS config files?
- copy/paste via SSH is so much easier than submitting through the GUI
Jarred - Apex Computers (Australia)
Image

bloater99
Posts: 482
Joined: October 13th, 2014, 3:47 pm

Re: Example Customized QoS

Post by bloater99 » January 8th, 2016, 2:51 pm

apexcomputers wrote:bloater99 any chance of getting the code from your QoS config files?
- copy/paste via SSH is so much easier than submitting through the GUI
I already did, on the first page of this thread:
viewtopic.php?f=27&t=13571#p90378
Image

Image

Post Reply