Ping watchdog that power off AP until uplink restored.
-
Eric Stern - Employee
- Posts: 532
- Joined: Wed Apr 09, 2014 9:41 pm
- Location: Toronto, Ontario
- Has thanked: 0 time
- Been thanked: 130 times
Re: Ping watchdog that power off AP until uplink restored.
I'll add it to my list of things to do.
Re: Ping watchdog that power off AP until uplink restored.
Hi Eric,
I'm absolutely desperate for this functionality at a couple of sites and having to do crazy hacks to workaround. I'm willing to try beta firmware if it's nowhere near RC?
I'm absolutely desperate for this functionality at a couple of sites and having to do crazy hacks to workaround. I'm willing to try beta firmware if it's nowhere near RC?
-
Eric Stern - Employee
- Posts: 532
- Joined: Wed Apr 09, 2014 9:41 pm
- Location: Toronto, Ontario
- Has thanked: 0 time
- Been thanked: 130 times
Re: Ping watchdog that power off AP until uplink restored.
Are you sure this would actually work for you? If a failing ping turns on the power to your backup link, once the backup link is active won't the ping start succeeding again? Because once the ping succeeds it will turn off the power to the backup link again.
Re: Ping watchdog that power off AP until uplink restored.
The automatic "off" functionality isn't as important as I get an alert if routes change anyway. Most important thing is that the "ping fails, turn port on feature" so the reserve connection can kick in and essentially bring the tower back to life.
On a different note, it's great being able to easily automatically turn on and off higher powered radios when voltage changes (e.g. solar panels in snow turns on Airmax radio and turns off SAF radio) or on a time schedule (e.g. 1am to 6am) etc.
On a different note, it's great being able to easily automatically turn on and off higher powered radios when voltage changes (e.g. solar panels in snow turns on Airmax radio and turns off SAF radio) or on a time schedule (e.g. 1am to 6am) etc.
-
Eric Stern - Employee
- Posts: 532
- Joined: Wed Apr 09, 2014 9:41 pm
- Location: Toronto, Ontario
- Has thanked: 0 time
- Been thanked: 130 times
Re: Ping watchdog that power off AP until uplink restored.
I created 1.4.8rc8 for you. It has an "Enable Power" action for the watchdog.
http://forum.netonix.com/firmware/testi ... 4.8rc8.bin
http://forum.netonix.com/firmware/testi ... 4.8rc8.bin
Re: Ping watchdog that power off AP until uplink restored.
Thanks...I'll do some bench testing tomorrow and let you know if any obvious issues.
Re: Ping watchdog that power off AP until uplink restored.
Hi Eric,
Thanks for your earlier work but I think Watchdog still needs enhancement.
Basically it's not working if a radio isn't powered on as a default....I'm guessing that's because it wouldn't know the voltage configuration to apply.
It really needs an option to disable the power on successful ping as well as failure.
I do have workarounds at the moment but they're very tedious and make things overly complex.
e.g.
At present, I have to set the failover radio default as switched on (say 24V).
Set the watchdog to
a) Power on failover radio if router IP facing interface on far end of primary radio fails
b) Power off failover radio if TEST IP on the local router (directly connected to netonix) fails.
For the TEST IP to fail (the trigger), I have to create a TEST IP on a dummy bridge on the local router. On that router I then have to run a script / netwatch at 1m intervals to disable the TEST IP if the router IP facing the interface on far end of primary radio SUCCEEDS (essentially the opposite of (a)) and re-enable the TEST IP if it FAILS.
NOTE: I use overlapping /29s on the interfaces facing each end of the radio link so that ICMP can only succeed if the primary radio is working. A simple input filter on source IP or incoming port would also work on the far end router.
I think this should also have an over-ride checkbox to tie in with the POWER (voltage and times) options.
Thanks for your earlier work but I think Watchdog still needs enhancement.
Basically it's not working if a radio isn't powered on as a default....I'm guessing that's because it wouldn't know the voltage configuration to apply.
It really needs an option to disable the power on successful ping as well as failure.
I do have workarounds at the moment but they're very tedious and make things overly complex.
e.g.
At present, I have to set the failover radio default as switched on (say 24V).
Set the watchdog to
a) Power on failover radio if router IP facing interface on far end of primary radio fails
b) Power off failover radio if TEST IP on the local router (directly connected to netonix) fails.
For the TEST IP to fail (the trigger), I have to create a TEST IP on a dummy bridge on the local router. On that router I then have to run a script / netwatch at 1m intervals to disable the TEST IP if the router IP facing the interface on far end of primary radio SUCCEEDS (essentially the opposite of (a)) and re-enable the TEST IP if it FAILS.
NOTE: I use overlapping /29s on the interfaces facing each end of the radio link so that ICMP can only succeed if the primary radio is working. A simple input filter on source IP or incoming port would also work on the far end router.
I think this should also have an over-ride checkbox to tie in with the POWER (voltage and times) options.
Re: Ping watchdog that power off AP until uplink restored.
Is this in the too hard basket?
Re: Ping watchdog that power off AP until uplink restored.
Ok, for anyone that cares and is using a solar site with redundant links with Mikrotik router, here is what I'm doing to only switch the redundant links on when required..
On my upstream links I'm using /29's. e.g.
/ip address add address=172.16.1.188/29 interface=ether5-AF5X-MainBH-Trunk network=172.16.1.184
/ip route add comment="default gateway for main uplink" distance=179 gateway=172.16.1.185
/ip address add address=172.16.1.132/29 interface=vlan311-M5-ReserveBH network=172.16.1.128
/ip route add comment="default gateway for failover uplink" distance=180 gateway=172.16.1.129
(the static routes aren't necessary with OSPF but I'm using them as example)
I then create an IP address facing the netonix for my redundancy netwatch. e.g.
/ip address add address=172.31.1.185 comment=NetonixAF5Xwatchdog disabled=yes interface=ether2-netonix2-Mgmt
And associated netwatch script pointing at the next upstream hop IP (as it's /29 then it can only be seen over the primary upstream link)
/tool netwatch
add down-stript="/ip address enable [find address="\"172.31.1.185/32\"]" host=\172.16.1.185 interval=30s timeout=200ms up-script=\"/ip address disable [find address=\"172.31.1.185/32\"]"
Then I add the WATCHDOG on the netonix to switch on and off the redundant link as required.
You could combine with the POWER option to switch off the primary upstream link when voltage is low or at certain hours of the day when usage is low.
EDIT: In the above image, untick Notify on enable power (disable is fine) as they keep coming through if you have configured SMTP on the Netonix.
On my upstream links I'm using /29's. e.g.
/ip address add address=172.16.1.188/29 interface=ether5-AF5X-MainBH-Trunk network=172.16.1.184
/ip route add comment="default gateway for main uplink" distance=179 gateway=172.16.1.185
/ip address add address=172.16.1.132/29 interface=vlan311-M5-ReserveBH network=172.16.1.128
/ip route add comment="default gateway for failover uplink" distance=180 gateway=172.16.1.129
(the static routes aren't necessary with OSPF but I'm using them as example)
I then create an IP address facing the netonix for my redundancy netwatch. e.g.
/ip address add address=172.31.1.185 comment=NetonixAF5Xwatchdog disabled=yes interface=ether2-netonix2-Mgmt
And associated netwatch script pointing at the next upstream hop IP (as it's /29 then it can only be seen over the primary upstream link)
/tool netwatch
add down-stript="/ip address enable [find address="\"172.31.1.185/32\"]" host=\172.16.1.185 interval=30s timeout=200ms up-script=\"/ip address disable [find address=\"172.31.1.185/32\"]"
Then I add the WATCHDOG on the netonix to switch on and off the redundant link as required.
You could combine with the POWER option to switch off the primary upstream link when voltage is low or at certain hours of the day when usage is low.
EDIT: In the above image, untick Notify on enable power (disable is fine) as they keep coming through if you have configured SMTP on the Netonix.
Last edited by scracha on Thu Jun 14, 2018 11:21 pm, edited 1 time in total.
- tas
- Member
- Posts: 6
- Joined: Mon May 21, 2018 5:33 pm
- Has thanked: 0 time
- Been thanked: 0 time
Re: Ping watchdog that power off AP until uplink restored.
@scracha - Thanks for this
Who is online
Users browsing this forum: Google [Bot] and 4 guests