Community discussions

MikroTik App
 
farahf
just joined
Topic Author
Posts: 6
Joined: Thu Nov 13, 2014 3:40 pm

How do I print simple queues with no target?

Fri Oct 09, 2015 3:49 pm

I need to print the queues with target=unknown. How should I filter for them?
/queue simple print where target=??
The queue target becomes empty when a client is offline.

Thanks
 
User avatar
strods
MikroTik Support
MikroTik Support
Posts: 1662
Joined: Wed Jul 16, 2014 7:22 am
Location: Riga, Latvia

Re: How do I print simple queues with no target?

Sat Oct 10, 2015 5:54 am

What do you mean with traget=unknown? Do you mean target=0.0.0.0/0?

You can not create queue without specifying the target.

Usually to find something what has no value you should use "!".

Example:
"/ip firewall filter print where !src-address"
 
farahf
just joined
Topic Author
Posts: 6
Joined: Thu Nov 13, 2014 3:40 pm

Re: How do I print simple queues with no target?

Sat Oct 10, 2015 1:14 pm

What do you mean with traget=unknown? Do you mean target=0.0.0.0/0?

You can not create queue without specifying the target.

Usually to find something what has no value you should use "!".

Example:
"/ip firewall filter print where !src-address"

Tried it, did not work :(

Scenario:

I add a simple queue and assign target to a connected PPPoE client. But after the client gets disconnected, the target becomes unknown. I need to clean up any unassigned queues. To find them I need to filter them by the empty target.
 
farahf
just joined
Topic Author
Posts: 6
Joined: Thu Nov 13, 2014 3:40 pm

Re: How do I print simple queues with no target?

Mon Oct 12, 2015 4:07 pm

I found a solution, API syntax:
/queue/simple/print ?<target=0 
 
markdyer
just joined
Posts: 8
Joined: Thu Apr 16, 2015 3:14 am

Re: How do I print simple queues with no target?

Thu Apr 12, 2018 3:36 am

/queue simple> print where invalid !disabled