Community discussions

MikroTik App

Search found 21 matches

by dfdf
Sun Jan 08, 2023 2:59 pm
Forum: Scripting
Topic: Can somebody explain how this script works?
Replies: 4
Views: 587

Re: Can somebody explain how this script works?

I know about semicolons. that's doesn't matter, i prefer C-like style writing. Routerboard info is above in my initial post, but this behavior is observed on different devices. I was finding a way to have a global function with generated name (stored in variable). Smth. alike (not working): :local f...
by dfdf
Sun Jan 08, 2023 1:48 pm
Forum: Scripting
Topic: Can somebody explain how this script works?
Replies: 4
Views: 587

Can somebody explain how this script works?

I was testing some script to allow variable function name. And suddenly found very confusing result for this short script. Tested on ROS 6.49 and 7.6. Can someone explain how it works? :local cookie "someName"; :local cookieCode do={ :put "TestIt"; /system routerboard print; }; [...
by dfdf
Tue Nov 29, 2022 7:02 pm
Forum: RouterOS beta and rc versions
Topic: RDP Connection Dying
Replies: 51
Views: 17210

Re: RDP Connection Dying

I have the same problem with RDP on Windows Server 2012 R2. I managed to force the end the cyclic disconnection by reducing the MTU from 1500 to 1492. I reported a problem with version 7.x and RDP to technical support. I think he doesn't believe me, than this problem exist. Also write to them, if t...
by dfdf
Fri Nov 25, 2022 11:12 pm
Forum: Scripting
Topic: Script for recursive failover based on packet loss
Replies: 7
Views: 1106

Re: Script for recursive failover based on packet loss

:local "stat_period" (5*60); :local "traffic"; :local "tx-packets-per-second"; :local "rx-packets-per-second"; :local "packet_tx_drops_rate"; :local "packet_rx_drops_rate"; #:local "packet_tx_errors_rate"; #:local "packet_rx...
by dfdf
Thu Nov 24, 2022 4:53 am
Forum: RouterOS beta and rc versions
Topic: /system routerboard usb power-reset duration=9999d
Replies: 0
Views: 378

/system routerboard usb power-reset duration=9999d

Hello, I'm having issue with ROS 7.6 regarding to /system routerboard usb power-reset duration=9999d In ROS 6 I was able to issue /system routerboard usb power-reset duration=9999d /system routerboard usb power-reset duration=0 and didn't get any error, but in ROS 7 if I do the same, I'm getting &qu...
by dfdf
Wed Nov 16, 2022 12:11 am
Forum: Scripting
Topic: ✂ Rextended Fragments of Snippets
Replies: 34
Views: 18560

Re: ✂ Rextended Fragments of Snippets

decimal 2 binary (only 1 byte) :global dec2bin do={ ... } Consider this way (accepts range 0...2 147 483 647): :global "dec2bin" do={ :local "in" [:tonum $1]; :local "out" ""; :local "start" (1); :for "i" from=8 to=32 step=8 do={ :if (($&q...
by dfdf
Mon Nov 14, 2022 12:31 am
Forum: Scripting
Topic: Sorted array of files [SOLVED]
Replies: 13
Views: 3403

Re: Sorted array of files [SOLVED]

There's more elegant way to sort array using built-in mikrotik array sorting in case of key-value array. This https://forum.mikrotik.com/viewtopic.php?f=9&t=178532#p879931 hack is nice, but we can achieve same result without global tmpsortlist. Tested on ROS 6 & 7. My hack idea is in this li...
by dfdf
Fri Nov 11, 2022 10:34 pm
Forum: RouterOS beta and rc versions
Topic: "Detect internet" strange behavior ROS 7.0-7.6
Replies: 8
Views: 760

Re: "Detect internet" strange behavior ROS 7.0-7.6

Well, to satisfy mobile app without messing up interface lists the best config is, as I understand:
> /interface/detect-internet/ print
detect-interface-list: WAN
lan-interface-list: none
wan-interface-list: none
internet-interface-list: none
by dfdf
Fri Nov 11, 2022 9:54 pm
Forum: RouterOS beta and rc versions
Topic: I have two Internet links. I wanted to use Link 1 first and then overflow traffic shift to Link 2.
Replies: 2
Views: 571

Re: I have two Internet links. I wanted to use Link 1 first and then overflow traffic shift to Link 2.

I suppose it's possible by means of measurements of /interface/monitor-traffic interface=wan do=route.to.link2.script the script is not trivial at all, meaning all current connections must persist, and new connections should be made over link2. This can be achieved by routing marks (not script) in f...
by dfdf
Fri Nov 11, 2022 9:20 pm
Forum: RouterOS beta and rc versions
Topic: Minor windox(?) issue
Replies: 2
Views: 388

Re: Minor windox(?) issue

Try clearing the cache before you login using the Tools->Clear Cache option.
Didn't help as expected, due to to completely unrelated to problem described.
by dfdf
Fri Nov 11, 2022 9:15 pm
Forum: RouterOS beta and rc versions
Topic: Feature request: allow dns name(s) for IP servicies
Replies: 3
Views: 457

Re: Feature request: allow dns name(s) for IP servicies

Can't you do: /ip/firewall/filter/add action=accept chain=input dst-port=8291 protocol=tcp src-address-list=your-address-list ? I can. I will. Moreover, I have to (or it will not work at all if router has firewall rules enabled). But this MEANS I also need to allow service from everywhere -- not th...
by dfdf
Tue Nov 08, 2022 11:33 pm
Forum: RouterOS beta and rc versions
Topic: Minor windox(?) issue
Replies: 2
Views: 388

Minor windox(?) issue

Having "detect internet state" window open in winbox after reboot turns into two windows "Detect internet". See attachments.
by dfdf
Tue Nov 08, 2022 9:59 pm
Forum: RouterOS beta and rc versions
Topic: "Detect internet" strange behavior ROS 7.0-7.6
Replies: 8
Views: 760

"Detect internet" strange behavior ROS 7.0-7.6

I have a long-lasting issue with "Detect internet" status. It doesn't work after reboot, until I change and revert (even without pressing 'apply' button) any of lists in "Detect internet" dialog box. After this manipulation "Detect internet" status works fine until next...
by dfdf
Tue Nov 08, 2022 9:43 pm
Forum: RouterOS beta and rc versions
Topic: Feature request: allow dns name(s) for IP servicies
Replies: 3
Views: 457

Feature request: allow dns name(s) for IP servicies

I can have address list filled dynamically by dns name resolution and use this list in firewall rules. But currently I don't have ability to limit ip service (such as winbox or ssh) to be available only to dns name -- only to IP address/IP subnet. So suppose I have a dynamic IP for place I want to c...
by dfdf
Wed May 11, 2022 11:29 pm
Forum: Announcements
Topic: v7.2.2 [stable] and v7.2.3 [stable] are released!
Replies: 401
Views: 63809

Re: v7.2.2 [stable] and v7.2.3 [stable] are released!

After upgrade to 7.2.3 getting "cpu not running on default frequency" on RBD52G-5HacD2HnD (hap ac2).
Bug?
by dfdf
Fri Apr 01, 2022 11:47 pm
Forum: Announcements
Topic: v7.1.4 and v7.1.5 is released!
Replies: 202
Views: 30518

Re: v7.1.4 and v7.1.5 is released!

check-gateway is unrelated to unreachable as it's a method to check reachability, not a result of checking. will try to use "/ip route print where inactive and !disabled"... still not sure this will cover all possible states and is equivalent to "unreachable" Please explain you ...
by dfdf
Fri Apr 01, 2022 12:38 am
Forum: Announcements
Topic: v7.1.4 and v7.1.5 is released!
Replies: 202
Views: 30518

Re: v7.1.4 and v7.1.5 is released!

Maybe you can work around it by using: where check-gateway and inactive check-gateway is unrelated to unreachable as it's a method to check reachability, not a result of checking. will try to use "/ip route print where inactive and !disabled"... still not sure this will cover all possible...
by dfdf
Fri Apr 01, 2022 12:19 am
Forum: Announcements
Topic: v7.1.4 and v7.1.5 is released!
Replies: 202
Views: 30518

Re: v7.1.4 and v7.1.5 is released!

You can create a bridge "unreachable" without ports and addresses, then route the traffic there. Now create a firewall rule to match packets to that interface and reject.
/ip route print. I don't want to create anything, just to filter out unreachable routes in PRINT command.
by dfdf
Fri Apr 01, 2022 12:17 am
Forum: Announcements
Topic: v7.1.4 and v7.1.5 is released!
Replies: 202
Views: 30518

Re: v7.1.4 and v7.1.5 is released!

You can now only use "blackhole" for a similar function. I just want to filter out unreachable routes, it's absolutely unrelated to blackhole property, as blackhole is another type of route. How can I do this in 7.x.x? It was a fundamental property on which many scripts rely on. Why it's ...
by dfdf
Fri Apr 01, 2022 12:00 am
Forum: Announcements
Topic: v7.1.4 and v7.1.5 is released!
Replies: 202
Views: 30518

Re: v7.1.4 and v7.1.5 is released!

Hello,
in 6.x.x ROS there was "unreachable" property for every route in /ip route
It's gone in 7.x.x? Why? And what should I use instead of it in scripts?
by dfdf
Sun Mar 13, 2022 4:33 pm
Forum: General
Topic: Wireguard vpn services
Replies: 5
Views: 2140

Re: Wireguard vpn services

No need to use Surfshark app, WG client works if use this: https://github.com/Incognito-Coder/Wiregen BUT unfortunately currently i was unable to work out working config for Mikrotik router (getting 'Handshake for peer did not complete after 5 seconds, retrying') while WG client allows me to have a ...