Ad Widget

Collapse

Error trying to monitorize AWS EC2 and S3 from Zabbix 6.4.5

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Javivu
    Junior Member
    • Aug 2023
    • 12

    #1

    Error trying to monitorize AWS EC2 and S3 from Zabbix 6.4.5

    Hi to all! I'm trying to monitorize my AWS infra from my Zabbix Server 6.4.5.
    I'm using the official templates for 6.4.5 , the template aws_http
    I follow all the steps:
    1. Create the IAM policie
    2. Create the user and assign iam policie
    3. Create access key for the user
    4. Create host and:
      1. assign template aws_http
      2. assign group
      3. configure 3 macros: {$AWS.ACCESS.KEY.ID}, {$AWS.SECRET.ACCESS.KEY}, {$AWS.REGION} for the host
    5. Then I enable in the host --> discovey rules:
      1. EC2 instances discovey
      2. S3 buckets discovery
    6. Then i recieve the error in both discovery rules: Cannot find the "data" array in the received JSON object​
    Any help?

    Thanks!
  • BigSmooth
    Member
    • Jun 2023
    • 46

    #2
    Hi,
    Did you checked zabbix logs (/var/log/zabbix/zabbix_server.log)?
    It usually give more insights.
    Regards,
    Olivier

    Comment

    • Javivu
      Junior Member
      • Aug 2023
      • 12

      #3
      Thanks, but zabbix_server.log not show any log about this host (errors, warning, etc)
      Click image for larger version

Name:	zabbix_aws_error.png
Views:	419
Size:	45.1 KB
ID:	472008

      Comment

      • BigSmooth
        Member
        • Jun 2023
        • 46

        #4
        You should try to increase log level of Zabbix server or, as I did, modify the javascript in discovery rule script.

        Comment

        • cyber
          Senior Member
          Zabbix Certified SpecialistZabbix Certified Professional
          • Dec 2006
          • 4807

          #5
          I have a suspicion, that your discovery script fails and you just do not get any data. Please verify at first, if you get any data...

          Comment

          • Javivu
            Junior Member
            • Aug 2023
            • 12

            #6
            Hi to all and thanks for your help. Now only EC2 discovery are ok
            I describe my path to solution...
            1. I try to up the level log to 4, and see a lot of info about EC2 discovery but zero log from S3 discovery
            2. I think cyber and bigsmooth is on right, the script fails and give a error, but with debug log = 4 no print info about that
            3. Then i see that there is a new version of template, and download and import this new version for Zabbix 6.4.7
            4. I retry all the process describe in the first point and... .voala! I see all info about EC2 but not S3 services
            PD: from past version, in the new version there is a new macro named "{$AWS.AUTH_TYPE}" for config access_key or role_based (I use access_key)
            I try to research... but for me it's to hard to modify the javascript​

            Comment

            Working...