I setup a very simple script to disable simple queue counters - I removed all policy settings, so am expecting the script to not work:
[admin@RB750Gr3] > /system script print
Flags: I - invalid
0 name="Reset Simple Queue Counters" owner="admin"
last-started=mar/18/2017 23:36:45 run-count=7
source=/queue simple reset-counters-all
Running the script using the “Run Script” button in Winbox does what I expect - counters are not reset.
In the log the permission failure is confirmed by the entry:
[admin@RB750Gr3] > /log print follow-only
mar/18 23:56:09 script,error script error: not enough permissions (9)
This is all good.
However, running the script from a winbox terminal window does reset the counters.
[admin@RB750Gr3] > /queue simple print packets
Flags: X - disabled, I - invalid, D - dynamic
# NAME TARGET PACKETS
0 Gue.. 10.81.196.31/32 14/15
1 Gue.. 10.81.196.32/32 0/0
[admin@RB750Gr3] > /system script run "Reset Simple Queue Counters"
[admin@RB750Gr3] > /queue simple print packets
Flags: X - disabled, I - invalid, D - dynamic
# NAME TARGET PACKETS
0 Gue.. 10.81.196.31/32 0/0
1 Gue.. 10.81.196.32/32 0/0
Why?