Hi All,
We are attempting to create a script that :
Deletes all queues where
1) Name contains the word "hotspot" AND
2) IP Address NOT in a specified subnet
The first part works with the name, but we can't seem to get the IP Address section to work.
here is our code:
/queue simple {
:foreach item in=[find name ~"hotspot" && target in !="1.1.1.0/24"] do={
remove $item
}
}
Here is the queue that should be deleted :
[admin@MikroTik] /queue simple> pr
Flags: X - disabled, I - invalid, D - dynamic
0 name="hotspot" target=2.2.2.2/32 parent=none packet-marks="" priority=8/8 queue=default-small/default-small limit-at=0/0 max-limit=0/0
burst-limit=0/0 burst-threshold=0/0 burst-time=0s/0s bucket-size=0.1/0.1
Can someone assist please? Thank You