1
General Discussion / monit gateway_alert only works for gateway groups
« on: November 11, 2023, 10:54:04 am »
Hello, there!
Is there any reason why the monit gateway_alert only works for gateway groups?
My Tunnelbroker gateway went down, but I didn't get any monit notifications, as I would've expected. Looking at monit status, it was showing "OK":
So I looked at the check script in /usr/local/opnsense/scripts/OPNsense/Monit/gateway_alert and noticed all checks are wrapped in an if (isset($config['gateways']['gateway_group'])) {}.
Is there any particular reason for that? As I said, I would expect to get "gateway down" notifications regardless of if I have gateway groups defined or not.
Is there any reason why the monit gateway_alert only works for gateway groups?
My Tunnelbroker gateway went down, but I didn't get any monit notifications, as I would've expected. Looking at monit status, it was showing "OK":
Code: [Select]
Program 'gateway_alert'
status OK
monitoring status Monitored
monitoring mode active
on reboot start
last exit value 0
last output -
data collected *~1 minute ago*
So I looked at the check script in /usr/local/opnsense/scripts/OPNsense/Monit/gateway_alert and noticed all checks are wrapped in an if (isset($config['gateways']['gateway_group'])) {}.
Is there any particular reason for that? As I said, I would expect to get "gateway down" notifications regardless of if I have gateway groups defined or not.