[Nut-upsuser] NOTIFYCMD doesn't work at all... not fully
Charles Lepple
clepple at gmail.com
Thu Oct 6 11:41:02 UTC 2016
> On Oct 6, 2016, at 6:15 AM, Stefan Fröchtenicht wrote:
>
> when i execute the upsnotify.sh as root, then it works great. eMails and SMS are incoming.
> But when i for e.g. pull out the ups from power, then there will be only emails and NO SMS. Why?
>
NUT runs the notify script as the "nut" user on many systems, including Debian. Check to see if $PATH is set the same, and that the nut user has privileges to run the SMS program.
You could also try temporarily wrapping the SMS portion in a subshell that pipes stdout/stderr to mail (or a file):
( echo "..." | gammu-smsd-inject ... ) 2>&1 | mail -s "errors from SMS" $EMAIL
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20161006/31f86c60/attachment.html>
More information about the Nut-upsuser
mailing list