How to setup Automation & Alerts to get notified when active interface changes

Hi,

I’d like to setup my TRB units to send out a notification and disable Tailscale when the active internet connection changes to ‘mobile’.
The main internet connection is though the eth ‘wan’ connection.

I cannot find a option to trigger on change, it only looks for current state.
Do I miss something here or is there another way of configuring this?

Thanks!

Hello,

After discussing this with the RMS team, it looks like they have created a request for the R&D team to implement this functionality in RMS itself - no ETA for this one as of yet. For the TRB devices themselves, there will also be a “Failover” functionality, same as in our other devices. The current ETA is for the firmware version 7.16 which the release date has not yet been announced.

If this functionality is something you really need, you may opt for custom scripts, but do note that they might use immense amounts of data. I’ll explain the logic below so you’ll have a better understanding of why.

If you are able to wait, and if the feature is not necessary to have at this given moment, then as I said, you’ll have to wait until Firmware version 7.16

For the custom script logic, you basically want to keep sending pings from X interface to let’s say google.com or 8.8.8.8 or whatever host you desire. Once a response is stopped being received, you send a command to switch the interface, or, as you said, stop the tailscale service, and also send an SMS (or e-mail) to notify you of the action happening. You may find custom script examples here: User Scripts examples - Teltonika Networks Wiki

I found an old OpenWRT thread for a custom script to failover between 2 interfaces, you can check it out, might find something useful here: OpenWrt Forum Archive

Regards,
M.