Page 1 of 1

Youtube Bandwidth

Posted: Tue Jul 29, 2014 10:49 pm
by z3ro647
Hi,
I know it is possible to limit download and upload using a simple queue but what i was trying is that if i mark a limit say 256 k download and 256 k for upload then everything even youtube will also get 256 k download and upload bandwidth. I want to make every connection to have 256 k download and upload except youtube. can we make youtube to have unlimited bandwidth and other to have 256 k speed.

Re: Youtube Bandwidth

Posted: Wed Jul 30, 2014 9:44 am
by CyberTod
I am using this and it works for me :
/ip firewall mangle add action=add-dst-to-address-list address-list=Youtube address-list-timeout=10m chain=prerouting comment=youtube content=youtube.com dst-port=80,443 protocol=tcp
/ip firewall mangle add action=mark-packet chain=forward comment=youtube new-packet-mark=Youtube passthrough=no src-address-list=Youtube
Then you can add a queue with higher limit for these marked packets.

Re: Youtube Bandwidth

Posted: Wed Jul 30, 2014 6:09 pm
by z3ro647
Sorry but it didn't worked. i mean after i added the code and created a simple queue with the maximum download and upload limit of 256kbps speed. Youtube video starts to buffer. :cry:
please help.........

Re: Youtube Bandwidth

Posted: Wed Jul 30, 2014 6:13 pm
by z3ro647
sorry It didn't worked after i added the code then i created a simple queue of maximum download and upload of 256kbps but still Youtube starts to buffer...... :(
please help...........

Re: Youtube Bandwidth

Posted: Fri Aug 01, 2014 4:35 pm
by CyberTod
And did you add another queue before this with the 256k limit to give these marked packets lets say 2Mbit

Re: Youtube Bandwidth

Posted: Sun Aug 03, 2014 9:18 pm
by z3ro647
How did you do that.... i mean i am still stuck in same problem and i have tried so many times but still not working....... after adding the scrip i created a queue like this....

Re: Youtube Bandwidth

Posted: Sun Aug 03, 2014 10:12 pm
by CyberTod
This is wrong.
The parent queue should have no marks attached to it, only all your available bandwidth.
Then you have another queue for Youtube - packet mark Youtube and higher bandwidth with all bandwidth as the parent
Then is your laptop Lan queue - again All bandwidth as parent, the ip as target and no packet marks attached

Re: Youtube Bandwidth

Posted: Sun Aug 03, 2014 11:08 pm
by z3ro647
ops
it works fine when i download some file from internet. The download speed is 256 kbps with the queue. But on youtube its not working. Youtube is not playing video beyond 256 kbps internet speed.

Re: Youtube Bandwidth

Posted: Sun Aug 03, 2014 11:14 pm
by CyberTod
The order of the rules is very important. You have ordered by name. Order by number and put the Youtube rule above the 256k one.

Re: Youtube Bandwidth

Posted: Sun Aug 03, 2014 11:36 pm
by z3ro647
Thanks CyberTod
Finally working when i did like this........ :D
CyberTod where are you from??????

Re: Youtube Bandwidth

Posted: Sun Aug 03, 2014 11:48 pm
by CyberTod
I'm glad you got it working. I'm from Bulgaria.

Re: Youtube Bandwidth

Posted: Mon Aug 04, 2014 7:27 pm
by z3ro647
CyberTod do you have any solution related to the problem which is in this link.

http://forum.mikrotik.com/viewtopic.php ... 94#p440275

Re: Youtube Bandwidth

Posted: Mon Aug 11, 2014 12:30 pm
by raheel3148
dear CyberTod and all members,

i m from Pakistan and i m in trouble and need help. i m using mikrotik 6.5 version, in my service has a sharing server,(this server is my Internet service provider sharing server) i want that if my users connect from hotspot and pppoe server and dhcp server so they use internet according to his/her package, but! just get 4mbps downloding speed for dodear.com torrent and dodear.com websites.
please give me script so that i can implement this. i m new and i dont know how to do this

my lan server i.p: 192.168.0.1/24

dodear.com website i.p: 192.168.20.60

please please please help me and reply this email , i will be very thank full to you,


waiting for response ..


thanks and regards
Raheel

Re: Youtube Bandwidth

Posted: Thu Apr 02, 2015 10:39 pm
by rubence
hello cybertod and z3ro

youtube bandwidth is not working for me .... i cant make simple queue without target address ... as its showing network address is needed. so i enter 0.0.0.0/0 .. but its not working at all ..

Re: Youtube Bandwidth

Posted: Tue Apr 14, 2015 1:57 pm
by oxigeno20
Hello everybody!.
Is more efective mangle by IP

/ip fire addr
add address=173.194.0.0/16 disabled=no list=Youtube
add address=208.65.152.0/22 disabled=no list=Youtube
add address=64.15.112.0/20 disabled=no list=Youtube
add address=74.125.96.0/19 disabled=no list=Youtube
add address=72.14.221.0/24 disabled=no list=Youtube
add address=84.53.128.0/18 disabled=no list=Youtube
add address=87.248.192.0/19 disabled=no list=Youtube
add address=216.155.128.0/19 disabled=no list=Youtube
add address=208.73.208.0/21 disabled=no list=Youtube
add address=66.55.140.0/23 disabled=no list=Youtube
add address=74.125.208.0/24 disabled=no list=Youtube
add address=208.117.224.0/19 disabled=no list=Youtube

The only problem is that these IP addresses include other services like google adsense, and google CDN librarys, and may be others services. But Youtube is working very well.

http://www.tech-nico.com/blog/marcar-ip ... -servicio/

Re: Youtube Bandwidth

Posted: Sat May 23, 2015 12:12 pm
by amt
Hi CyberTod,

is working on v6.28 ? i tested but did not work.

Thanks.
I am using this and it works for me :
/ip firewall mangle add action=add-dst-to-address-list address-list=Youtube address-list-timeout=10m chain=prerouting comment=youtube content=youtube.com dst-port=80,443 protocol=tcp
/ip firewall mangle add action=mark-packet chain=forward comment=youtube new-packet-mark=Youtube passthrough=no src-address-list=Youtube
Then you can add a queue with higher limit for these marked packets.

Re: Youtube Bandwidth

Posted: Sat May 23, 2015 12:12 pm
by amt
Hi CyberTod,

is working on v6.28 ? i tested but did not work.

Thanks.
I am using this and it works for me :
/ip firewall mangle add action=add-dst-to-address-list address-list=Youtube address-list-timeout=10m chain=prerouting comment=youtube content=youtube.com dst-port=80,443 protocol=tcp
/ip firewall mangle add action=mark-packet chain=forward comment=youtube new-packet-mark=Youtube passthrough=no src-address-list=Youtube
Then you can add a queue with higher limit for these marked packets.

Re: Youtube Bandwidth

Posted: Sat May 23, 2015 8:35 pm
by chechito

Re: Youtube Bandwidth

Posted: Sat Oct 31, 2015 12:31 pm
by Abbasmcse
Hi All


Hope you are doing great
myself also can't create queue without target and even my don't know how to create queue like tree.
please help me to understand and explain bit about queue.


Thanks
Abbas
MT1.JPG

Re: Youtube Bandwidth

Posted: Sun Nov 01, 2015 4:10 pm
by Abbasmcse
Hi CyberTod

Hope you are doing great.
I am very weak in Mikrotik queuing, I can't create queue without target address even i don't know how to create queue like parent simple queue like tree. Pls help me to understand

Thanks
Abbas

Re: Youtube Bandwidth

Posted: Sun Nov 01, 2015 4:15 pm
by Abbasmcse
I am using this and it works for me :
/ip firewall mangle add action=add-dst-to-address-list address-list=Youtube address-list-timeout=10m chain=prerouting comment=youtube content=youtube.com dst-port=80,443 protocol=tcp
/ip firewall mangle add action=mark-packet chain=forward comment=youtube new-packet-mark=Youtube passthrough=no src-address-list=Youtube
Then you can add a queue with higher limit for these marked packets.



Hi Tod

Hope you are doing great
I am new in Mikrotik . can you please explain about simple queue as well because i can't create parent simple queue like this.


Thanks
Abbas

Re: Youtube Bandwidth

Posted: Tue Nov 17, 2015 9:34 am
by Abbasmcse
Hi Sir

what about Queue, Can you please explain how to create Queue ,

WAN IP address - 200.200.201.100/30
LAN IP address - 192.168.1.1


Thanks
Abbas

Posted: Wed Nov 18, 2015 4:19 pm
by ummar
Mangleing

Sent from my LG-D850 using Tapatalk

Re: Youtube Bandwidth

Posted: Thu Nov 19, 2015 11:36 am
by Abbasmcse
Ummar mangeling rules are created and i can see traffic is hitting on mangle rules but i only question is how to make Queue to accomplish this task .

Thanks
Abbas

Re: Youtube Bandwidth

Posted: Wed Sep 28, 2016 1:16 am
by Mosa
Does not work with me

Re: Youtube Bandwidth

Posted: Sun Oct 02, 2016 6:01 pm
by nigslaysa
marking UDP 443 does the job for capturing youtube traffic for me.

Re: Youtube Bandwidth

Posted: Wed Aug 01, 2018 2:25 pm
by Leinadmontilla
I am using this and it works for me :
/ip firewall mangle add action=add-dst-to-address-list address-list=Youtube address-list-timeout=10m chain=prerouting comment=youtube content=youtube.com dst-port=80,443 protocol=tcp
/ip firewall mangle add action=mark-packet chain=forward comment=youtube new-packet-mark=Youtube passthrough=no src-address-list=Youtube
Then you can add a queue with higher limit for these marked packets.
This not working

Re: Youtube Bandwidth

Posted: Wed Aug 01, 2018 2:26 pm
by Leinadmontilla
marking UDP 443 does the job for capturing youtube traffic for me.
Did you fine the answer for this?

Re: Youtube Bandwidth

Posted: Sun Aug 05, 2018 2:49 pm
by balkhodor
to mark youtube or Streaming packets

do the following.
1 - add layer 7 protocol
2- add mangle rule with mark packet
3- add queue and limit the speed.

step 1 : add layer7 protocol
name : streaming
regexp : videoplayback|video

mangle rule :
;;; http-video mark-connection
chain=prerouting action=mark-connection new-connection-mark=http-video passthrough=yes
layer7-protocol=video-streaming

4 ;;; http-video mark-packet
chain=prerouting action=mark-packet new-packet-mark=http-video passthrough=yes
connection-mark=http-video

add queue :
name="streaming" target=192.168.65.0/24 parent=none packet-marks=http-video priority=8/8
queue=default-small/default-small limit-at=0/0 max-limit=4M/4M burst-limit=0/0
burst-threshold=0/0 burst-time=0s/0s bucket-size=0.1/0.1



Mikrotik - Routing the World

Bilal Al Khodor

Re: Youtube Bandwidth

Posted: Fri Nov 23, 2018 6:11 pm
by Temorizador
Nice day , I mark connection and after packers of UDP 443 for youtube and any streeming UDP443 and work It works very well , too can mark the 80 udp port in the same mark conn if u want or use independent rules for 443 and 80 UDP port.

example 443,80 in same rules;
/ip firewall mangle 
 add action=mark-connection chain=prerouting connection-state=new new-connection-mark=UDP_443_80_conn passthrough=yes port=443,80 protocol=udp 
 add action=mark-packet chain=prerouting connection-mark=UDP_443_80_conn new-packet-mark=Streaming-Video-online_UDP_packet passthrough=no

/queue tree 
add name=Streaming_443_80_UDP_D packet-mark=Streaming-Video-online_UDP_packet parent="YOU PARENT LAN" priority=2
add name=Streaming_443_80_UDP_U packet-mark=Streaming-Video-online_UDP_packet parent="YOU PARENT WAN" priority=2
work fine , i hope it is usefull