Author |
Post |
|
#1 Fri Mar 19, 2021 10:37, 44 months ago.
|
Member
Registered: Mar 2021
|
Operating system name and version: OpenWrt 19.07.7 Version of smsd: 3.1.21 Smsd installed from: package repository Name and model of a modem / phone: Quectel EC200 Interface: USB
I have an OpenWRT router with smstools3 installed in a remote area, I configured a forward scripts with eventhandler so I can receive the SMS text via email. I want to add network connectivity check to eventhandler function in case the router loses internet and the SMS couldn't be sent through email. So I find the run_eventhandler() func in smsd.c, I want to add a network connectivity check(while loop) in this function, it will sleep until passing the network connectivity check, but I am not sure if this will cause any problem, will this works?
Any help will be appreciated.
|
|
#2 Wed Mar 24, 2021 15:24, 44 months ago.
|
Member
Registered: Apr 2011
Location: Viseu / Viseu / Portugal, Portugal
|
Hello!
What about an ping command with result to your sms response? For example ping www.nasa.gov and send to you the result in an sms!
Regards Rui
|
|
#3 Wed Apr 21, 2021 09:46, 43 months ago.
|
Member
Registered: Apr 2021
Location: Augsburg, Germany
|
Not so clear what you want to achive, may please provide some details. To check internet you may can use nagios plugin check_smtp:https://www.monitoring-plugins.org/doc/man/check_smtp.html This checks the availability of SMTP relay. You could use either eventhandler script or regular_run but I would avoid looping because it may block smsd process.
regards
Mike
|