Community discussions

MikroTik App
 
NightShadow
newbie
Topic Author
Posts: 40
Joined: Thu Jun 09, 2011 4:06 am

Help with Microtik traffic shaper

Mon Jul 04, 2011 5:39 pm

Hi could some one give me some advice please im using this system

http://wiki.mikrotik.com/wiki/TransparentTrafficShaper

i have my ip addresses set up from 192.168.1.1/192.168.1.254

At the moment everytime i have some one connecting to my router i have to set up a new set or rules for each Ip

i have tryed to put 192.168.1.0/32 so it will give the same amount of bandwith to each Ip but it wont accept it..

Is there away so it will give the same amont of bandwith to each Ip with out having to add more queues.

Thank you
 
fewi
Forum Guru
Forum Guru
Posts: 7734
Joined: Tue Aug 11, 2009 3:19 am

Re: Help with Microtik traffic shaper

Mon Jul 04, 2011 8:01 pm

Read the PCQ wiki.
Specific answers require specific questions. When in doubt, post the output of "/ip address print detail", "/ip route print detail", "/interface print detail", "/ip firewall export", and an accurate network diagram.
 
LastResort
just joined
Posts: 8
Joined: Sat Jan 01, 2011 8:28 am

Re: Help with Microtik traffic shaper

Sat Jul 09, 2011 5:26 am

PCQ is a great way to balance traffic between all users. If you're using Simple Queues to set data rates and track traffic volume, you can use this script:


Just replace the numbers with the ones you want. Edit in notepad. Cut and paste into "New Terminal" from Winbox. If you decide you don't like what you have you can select the queues from winbox and click the black "-" and they are gone.

Remember that the black "-" deletes whatever is highlighted and the red X disables. The familiar X upper right closes the window.

Winbox is pretty easy.

When you're done select "Files>Backup" and then drag the backup file to your desktop. It will have the entire router config including password.

The following script will create 241 simple queues from 172.26.0.10 to 172.26.0.250 with a traffic limit of 256k up and 1M down.

++++++=======Script Below This Line======++++++

:for i from=10 to=250 do={ /queue simple add name="$i" target-addresses="172.26.0.$i/32" dst-address=0.0.0.0/0 interface=all parent=none direction=both priority=8 queue=default-small/default-small limit-at=0/0 max-limit=256000/1000000 }

++++++======XXXXXXX======++++++

As an example, say you want to change the IP scope to 192.168.88.0 and the number of queues you want to create to 40 -

:for i from=11 to=50 do={ /queue simple add name="$i" target-addresses="192.168.88.$i/32" dst-address=0.0.0.0/0 interface=all parent=none direction=both priority=8 queue=default-small/default-small limit-at=0/0 max-limit=256000/1000000 }

If you want to change the max-limit just change those numbers. Once the queues are created, you can double click any queue in Winbox and modify as desired.

If something is broken in the script, like a return or improper character from the editor, Winbox will let you know exactly where the error is.

Your text editor can kill a script so make sure you keep it simple. You may want to disable word-wrap and make one long string before you copy and paste.

Who is online

Users browsing this forum: No registered users and 50 guests