Community discussions

MikroTik App
 
t3wera
newbie
Topic Author
Posts: 35
Joined: Mon Mar 02, 2009 2:39 am

help me in this que script

Sat May 08, 2010 11:41 am

hello , i`m try to make scrpit in que but ican`t
just iwant make script
same
search in queue simple if he find any que rule contain max-limit=1M/4M
change this queue to max-limit=256K/1M
any one can help me reaaly i`m tring to do it for 5hour but with more mistake :lol:
 
t3wera
newbie
Topic Author
Posts: 35
Joined: Mon Mar 02, 2009 2:39 am

Re: help me in this que script

Sun May 09, 2010 4:07 pm

wow 23 view no answer ithink i`m not bad more in english but ican explain what iwanna to do
iwant scrip same
:local traf;
/queue simple
  :for i from=3 to= 254 do =  {
    :if ([/queue simple find target-addresses=("196.81.56." . $i)] != "") do={
      :set traf [get [find target-addresses=("196.81.56." . $i)] total-bytes]
      :if ($traf  > 1073741824) do = {
        set [find target-addresses=("196.81.56." . $i)] max-limit= 81920/122880
      }
    }
  }
but search @ max-limit in rules of queues
if he found max-limit=256K/1M
do= set max-limit (to this rule)=500K/600K
this for example
really i miss this script more
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: help me in this que script

Mon May 10, 2010 5:46 am

maybe something like
/queue simple
set [ find max-limit=256K/1M ] max-limit=500K/600K
?..
 
t3wera
newbie
Topic Author
Posts: 35
Joined: Mon Mar 02, 2009 2:39 am

Re: help me in this que script

Mon May 10, 2010 1:37 pm

ido it but it doesn`t work server said it`s right but no cange in queues rule
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: help me in this que script

Mon May 10, 2010 1:58 pm

oh, I see. you should use
max-limit="256k/1M"
instead of
max-limit=256K/1M
 
t3wera
newbie
Topic Author
Posts: 35
Joined: Mon Mar 02, 2009 2:39 am

Re: help me in this que script

Mon May 10, 2010 5:17 pm

dosen`t work 2 :lol: itired from this script ithink no way ihave 3 day try to do this but ican`t all thing is k but no change in que
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: help me in this que script

Mon May 10, 2010 5:28 pm

have you changed "K" to "k"? I'll be at office in 15 minutes and will check again...
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: help me in this que script

Mon May 10, 2010 5:51 pm

here we go, ROS v4.6:
[admin@MikroTik] /queue simple> print 
Flags: X - disabled, I - invalid, D - dynamic 
 0    name="queue1" target-addresses=1.2.3.4/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=256k/1M 
      burst-limit=0/0 burst-threshold=0/0 burst-time=0s/0s 
      total-queue=default-small 
[admin@MikroTik] /queue simple> set [ find max-limit="256k/1M" ] max-limit=500k/600k  
[admin@MikroTik] /queue simple> print                                           
Flags: X - disabled, I - invalid, D - dynamic 
 0    name="queue1" target-addresses=1.2.3.4/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=500k/600k 
      burst-limit=0/0 burst-threshold=0/0 burst-time=0s/0s 
      total-queue=default-small 
[admin@MikroTik] /queue simple> 
 
kazanova
Member
Member
Posts: 406
Joined: Tue Sep 06, 2005 11:52 am

Re: help me in this que script

Mon May 10, 2010 8:01 pm

tested on 3.30 work good

Who is online

Users browsing this forum: No registered users and 24 guests