Community discussions

MikroTik App
 
sodisca
just joined
Topic Author
Posts: 7
Joined: Thu Feb 14, 2019 10:17 am

Unable to print oid for Queue Tree

Thu Feb 14, 2019 10:26 am

Hi,

I am having Mikrotik RB951G-2HnD with RouterOS 6.43.8.
I am trying to use Cacti to monitor my router queue bandwidth. I downloaded some templates with "Simple Queues" OID_INDEX: .1.3.6.1.4.1.14988.1.1.2.1.1.2. Apparently this does not work, I tried doing a snmpget, and this is my result:
snmpget -v2c -cpublic 192.168.xxx.xxx .1.3.6.1.4.1.14988.1.1.2.1.1.2
SNMPv2-SMI::enterprises.14988.1.1.2.1.1.2 = No Such Object available on this agent at this OID

I login to the router issue the command: [admin@MikroTik] > queue simple print oid, and this is what I get:
Flags: X - disabled, I - invalid, D - dynamic
[admin@MikroTik] >

Any reason why it is returning empty?

Thanks in advance.
 
ianngrh
newbie
Posts: 26
Joined: Thu Aug 30, 2018 6:53 am

Re: Unable to print oid for Queue Tree

Mon Feb 18, 2019 6:53 am

Hi sodisca,

If you want to print queue tree oid, you should use the /queue tree print oid command. Not /queue simple print oid.
Queue simple and queue tree is different thing.
 
sodisca
just joined
Topic Author
Posts: 7
Joined: Thu Feb 14, 2019 10:17 am

Re: Unable to print oid for Queue Tree

Mon Feb 18, 2019 7:35 am

Hi,
You are right, the command is different. Sorry about my subject title, I should have mention that both queue tree & queue simple command also response back with empty. Not sure why I am getting empty OID for both.

Hi sodisca,

If you want to print queue tree oid, you should use the /queue tree print oid command. Not /queue simple print oid.
Queue simple and queue tree is different thing.
 
ianngrh
newbie
Posts: 26
Joined: Thu Aug 30, 2018 6:53 am

Re: Unable to print oid for Queue Tree

Mon Feb 18, 2019 8:41 am

Have you tried to disable / enable the queue or simply reboot your RB, then do print oid.
Perhaps there is bug on the v. 6.43.8 ? (Just a guess).
Or try to upgrade to latest routerOS version.
 
User avatar
vecernik87
Forum Veteran
Forum Veteran
Posts: 882
Joined: Fri Nov 10, 2017 8:19 am

Re: Unable to print oid for Queue Tree

Mon Feb 18, 2019 9:38 am

FIY, I tried to replicate it and there is following result:
6.42.7 -
/queue simple print oid
works
6.43.2 -
/queue simple print oid
works
6.43.8 -
/queue simple print oid
works
6.44beta61 -
/queue simple print oid
works

All of them have practically same output which looks fine:
[admin@mikrotik] > /queue simple print oid
Flags: X - disabled, I - invalid, D - dynamic 
 0 XI  name=.1.3.6.1.4.1.14988.1.1.2.1.1.2.1 bytes-in=.1.3.6.1.4.1.14988.1.1.2.1.1.8.1 
      bytes-out=.1.3.6.1.4.1.14988.1.1.2.1.1.9.1 packets-in=.1.3.6.1.4.1.14988.1.1.2.1.1.10.1 
      packets-out=.1.3.6.1.4.1.14988.1.1.2.1.1.11.1 queues-in=.1.3.6.1.4.1.14988.1.1.2.1.1.12.1 
      queues-out=.1.3.6.1.4.1.14988.1.1.2.1.1.13.1 
I assume it is not version-related issue.

What happens when you do just a simple
/queue simple print
and
/queue simple export
? are these empty as well?
Are you certain that you have defined at least one queue?
 
sodisca
just joined
Topic Author
Posts: 7
Joined: Thu Feb 14, 2019 10:17 am

Re: Unable to print oid for Queue Tree

Mon Feb 18, 2019 10:27 am

Hi,

I think you are right, queue is empty, i issue the command:
[admin@MikroTik] /queue simple> print
Flags: X - disabled, I - invalid, D - dynamic

[admin@MikroTik] /queue simple> export
# feb/18/2019 01:31:42 by RouterOS 6.43.8
# software id = xxxx-xxxx
#
# model = 951G-2HnD
# serial number = xxxxxxxxx

I though there were already defined queue in the Router.

FIY, I tried to replicate it and there is following result:
6.42.7 -
/queue simple print oid
works
6.43.2 -
/queue simple print oid
works
6.43.8 -
/queue simple print oid
works
6.44beta61 -
/queue simple print oid
works

All of them have practically same output which looks fine:
[admin@mikrotik] > /queue simple print oid
Flags: X - disabled, I - invalid, D - dynamic 
 0 XI  name=.1.3.6.1.4.1.14988.1.1.2.1.1.2.1 bytes-in=.1.3.6.1.4.1.14988.1.1.2.1.1.8.1 
      bytes-out=.1.3.6.1.4.1.14988.1.1.2.1.1.9.1 packets-in=.1.3.6.1.4.1.14988.1.1.2.1.1.10.1 
      packets-out=.1.3.6.1.4.1.14988.1.1.2.1.1.11.1 queues-in=.1.3.6.1.4.1.14988.1.1.2.1.1.12.1 
      queues-out=.1.3.6.1.4.1.14988.1.1.2.1.1.13.1 
I assume it is not version-related issue.

What happens when you do just a simple
/queue simple print
and
/queue simple export
? are these empty as well?
Are you certain that you have defined at least one queue?
 
User avatar
vecernik87
Forum Veteran
Forum Veteran
Posts: 882
Joined: Fri Nov 10, 2017 8:19 am

Re: Unable to print oid for Queue Tree

Mon Feb 18, 2019 10:54 am

That would make sense. Unless you define the queue (simple or tree) yourself, there won't be any. Personally, I had to always create it from scratch to suit my needs, and as far as I know, there are no predefined/defconf queues.
However, even without queues, you can kind-of guess what OID will be used. As you can see on my code, the second-last number always changes based on property, while last number stays same - thats practically the ID of the queue. Therefore if you want to list all queues of any router, you can do snmpwalk on OID .1.3.6.1.4.1.14988.1.1.2.1.1.2 which will give you list of all names
 
sodisca
just joined
Topic Author
Posts: 7
Joined: Thu Feb 14, 2019 10:17 am

Re: Unable to print oid for Queue Tree

Wed Feb 20, 2019 5:38 am

Noted. Btw, this maybe off topic, I tried to create a simple queue with command below, then I get hit with error saying: "expected end of command (line 2 column 1)". Any idea what's wrong?

[admin@MikroTik] /queue simple> add name=private target=192.168.18.0/24 max-limit=10M/50M \
\... interface=ether1


That would make sense. Unless you define the queue (simple or tree) yourself, there won't be any. Personally, I had to always create it from scratch to suit my needs, and as far as I know, there are no predefined/defconf queues.
However, even without queues, you can kind-of guess what OID will be used. As you can see on my code, the second-last number always changes based on property, while last number stays same - thats practically the ID of the queue. Therefore if you want to list all queues of any router, you can do snmpwalk on OID .1.3.6.1.4.1.14988.1.1.2.1.1.2 which will give you list of all names
 
User avatar
vecernik87
Forum Veteran
Forum Veteran
Posts: 882
Joined: Fri Nov 10, 2017 8:19 am

Re: Unable to print oid for Queue Tree

Wed Feb 20, 2019 8:09 am

that is just syntax error: There is no "interface" parameter for simple queues.
You can easily list all available parameters with "TAB" key:
[admin@mikrotik] > /queue simple add  {[PRESSED TAB KEY]}
bucket-size  burst-threshold  comment    disabled  limit-at   name          parent        priority  time       target
burst-limit  burst-time       copy-from  dst       max-limit  packet-marks  place-before  queue     total-...  
Similarly, pressing question mark key will give more detailed info:
[admin@mikrotik] > /queue simple add {[PRESSED ? KEY]}
Creates new item with specified property values.

bucket-size -- 
burst-limit -- Maximal allowed burst of data rate in form of in/out
burst-threshold -- Average burst threshold in form of in/out
burst-time -- Burst time in form in/out
comment -- Short description of the item
copy-from -- Item number
disabled -- Defines whether item is ignored or used
dst -- 
limit-at -- Guaranteed data rate to this queue
max-limit -- Data rate which can be reached if there is enough bandwidth available
name -- Queue name
packet-marks -- 
parent -- Name of the parent queue in the hierarchy
place-before -- Item number
priority -- Flow priority
queue -- Queue type
target -- 
time -- At which time and day of week to allow this queue
total-bucket-size -- 
total-burst-limit -- Maximal allowed total (bidirectional) burst of data rate (bits/s)
total-burst-threshold -- Total (bidirectional) average burst threshold (bits/s)
total-burst-time -- Total burst (bidirectional) time
total-limit-at -- Allocated total (bidirectional) stream data rate (bits/s)
total-max-limit -- Maximal total (bidirectional) stream data rate (bits/s)
total-priority -- 
total-queue -- Queuing discipline to use for upload and download traffic

It is unfortunately not described there, but you can use the "target" parameter to specify interface, instead of IP range.
I guess more info can be found on wiki: https://wiki.mikrotik.com/wiki/Manual:Q ... dentifiers
 
sodisca
just joined
Topic Author
Posts: 7
Joined: Thu Feb 14, 2019 10:17 am

Re: Unable to print oid for Queue Tree

Wed Feb 20, 2019 8:22 am

Ahhh , ok, since I couldn't get interface to work, I use target instead.

Btw, by any chance have you use Cacti to monitor Mikrotik?

Thanks.

that is just syntax error: There is no "interface" parameter for simple queues.
You can easily list all available parameters with "TAB" key:
[admin@mikrotik] > /queue simple add  {[PRESSED TAB KEY]}
bucket-size  burst-threshold  comment    disabled  limit-at   name          parent        priority  time       target
burst-limit  burst-time       copy-from  dst       max-limit  packet-marks  place-before  queue     total-...  
Similarly, pressing question mark key will give more detailed info:
[admin@mikrotik] > /queue simple add {[PRESSED ? KEY]}
Creates new item with specified property values.

bucket-size -- 
burst-limit -- Maximal allowed burst of data rate in form of in/out
burst-threshold -- Average burst threshold in form of in/out
burst-time -- Burst time in form in/out
comment -- Short description of the item
copy-from -- Item number
disabled -- Defines whether item is ignored or used
dst -- 
limit-at -- Guaranteed data rate to this queue
max-limit -- Data rate which can be reached if there is enough bandwidth available
name -- Queue name
packet-marks -- 
parent -- Name of the parent queue in the hierarchy
place-before -- Item number
priority -- Flow priority
queue -- Queue type
target -- 
time -- At which time and day of week to allow this queue
total-bucket-size -- 
total-burst-limit -- Maximal allowed total (bidirectional) burst of data rate (bits/s)
total-burst-threshold -- Total (bidirectional) average burst threshold (bits/s)
total-burst-time -- Total burst (bidirectional) time
total-limit-at -- Allocated total (bidirectional) stream data rate (bits/s)
total-max-limit -- Maximal total (bidirectional) stream data rate (bits/s)
total-priority -- 
total-queue -- Queuing discipline to use for upload and download traffic

It is unfortunately not described there, but you can use the "target" parameter to specify interface, instead of IP range.
I guess more info can be found on wiki: https://wiki.mikrotik.com/wiki/Manual:Q ... dentifiers
 
harbinur
just joined
Posts: 4
Joined: Sat Nov 24, 2018 11:57 am

Re: Unable to print oid for Queue Tree

Fri Apr 05, 2019 12:45 pm

hi,
did you solve mikrotik cacti issue ?
 
sodisca
just joined
Topic Author
Posts: 7
Joined: Thu Feb 14, 2019 10:17 am

Re: Unable to print oid for Queue Tree

Mon Apr 08, 2019 6:59 am

Hi,
Unfortunately nope, I have been side track this couple of weeks due to other urgent issues to work on. Once I have time again I will look into this again and update.

Thanks.
hi,
did you solve mikrotik cacti issue ?
 
harbinur
just joined
Posts: 4
Joined: Sat Nov 24, 2018 11:57 am

Re: Unable to print oid for Queue Tree

Mon Apr 08, 2019 9:48 am

i don't know what is wrong on your side but i just wanted to describe what i did in my side for getting graphs from cacti in mikrotik.

First you need to enable snmp protocol from IP section, as seen on attached pictures.

After enabling snmp and add to the cacti as an host, it will automatically start to gather information from mikrotiks.

you can select device template type as generic snmp device which is enough to grab many graphs.
You do not have the required permissions to view the files attached to this post.
 
sodisca
just joined
Topic Author
Posts: 7
Joined: Thu Feb 14, 2019 10:17 am

Re: Unable to print oid for Queue Tree

Mon Apr 08, 2019 10:32 am

Thanks for sharing, will look into it.

i don't know what is wrong on your side but i just wanted to describe what i did in my side for getting graphs from cacti in mikrotik.

First you need to enable snmp protocol from IP section, as seen on attached pictures.

After enabling snmp and add to the cacti as an host, it will automatically start to gather information from mikrotiks.

you can select device template type as generic snmp device which is enough to grab many graphs.

Who is online

Users browsing this forum: No registered users and 30 guests