I don't understand why, but for some reason, "1Gbps" or "100Mbps" (which is what I did tests with...) are not treated by the inequality operator as strings... despite being strings according to :typeof (as is the value of $speed).
You need to explicitly quote the "1Gbps" for the operator to recognize it as a string, i.e.
I achieved the script to work,
but now I can't run the script from scheduler, if I place script name in scheduler it says that it runs in scheduler but it does not run
in scripts menu
when I place script content directly into schedulers "on event" field it works fine, script itself works without scheduler too if press 'run script'
interesting things are happening with routeros
Here is working script:
:global r
/interface ethernet monitor ether1 once do={
:set r $rate
}
it was " ; "'s fault, which was needed at the end of each if script was called from scheduler,
if script was run directly then it worked fine without " ; "