omni-lchen / zabbix-cloudwatch

71 stars 61 forks source link

SNS LLD no data in Zabbix #38

Closed dragan1979 closed 6 years ago

dragan1979 commented 6 years ago

Changed macro values (region,AWS account and region)

./awsLLD.py -a "default" -r "eu-west-1" -q "SNSTopics" -c 'topic' { "data": [ { "{#AWS_REGION}": "eu-west-1", "{#AWS_ACCOUNT}": "default", "{#TOPIC_INAME}": "", "{#TOPIC_NAME}": "topic" } ] }

AWS-CloudWatch-display name of zabbix-host localhost:zabbix server default-AWS account

./cron.SNS.sh "topic" "AWS-CloudWatch" "localhost" "default" "eu-west-1" {'host': 'AWS-CloudWatch', 'value': 2.0, 'key': u'SNS.NumberOfMessagesPublished.Sum["default","eu-west-1","topic"]', 'clock': 1532180160} {'host': 'AWS-CloudWatch', 'value': 2.0, 'key': u'SNS.NumberOfNotificationsDelivered.Sum["default","eu-west-1","topic"]', 'clock': 1532180160} {'host': 'AWS-CloudWatch', 'value': 0.0, 'key': u'SNS.NumberOfNotificationsFailed.Average["default","eu-west-1","topic"]', 'clock': 1532180160} Count: 3

Monitoring-Latest Data-empty

Imported example SNS template and attached it to host

capture

I tried AWS Lambda template and it works without issues, same output as for SNS template from terminal

dragan1979 commented 6 years ago

Managed to get it working:

had to copy awsLLD.sh to /usr/lib/zabbix/externalscripts/ after zabbix-service restart SNS data started to appear in Zabbix