Page 1 of 1

Problem with AWS SNS Notifications

Posted: Wed Jul 24, 2019 8:22 am
by Jaimito
Hello,

I am trying to configure Nagios to send notifications through the Amazon SNS service.

I have set up aws cli on the server where Nagios runs:
Captura de pantalla 2019-07-24 a las 15.10.15.png
When I launch a message with this command, it works correctly:
Captura de pantalla 2019-07-24 a las 15.10.52.png
But when I send a manual notification from the Nagios interface I have this error in the log:
Captura de pantalla 2019-07-24 a las 15.12.34.png
These are the commands that I have configured, I have simplified the commands to debug:

Code: Select all

define command {
  command_name    notify-host-by-sns
  command_line    aws sns publish --topic-arn arn:aws:sns:us-east-1:618665696336:nagios-notifications --message “Prueba host”
}

define command {
  command_name    notify-service-by-sns
  command_line    aws sns publish --topic-arn arn:aws:sns:us-east-1:618665696336:nagios-notifications --message “Prueba servicio”
}
The error it throws is as if I had not set up aws cli, but I did.

I appreciate your help, greetings!

Re: Problem with AWS SNS Notifications

Posted: Wed Jul 24, 2019 8:25 am
by scottwilkerson
It looks like you set it up as the ubuntu user, not as the nagios user