Open avkopylov opened 6 years ago
Zabbix 4.0 and I have the same issue.
Same problem here. Have anyone solve this?.
Sorry for late reply. In my Zabbix 4.0 environment, zaws script has be executed correctly.
Please check the zaws output by executing zaws command directly.
zaws ec2 list -r <your region name> -k <your aws access key id> -s <your aws secret key>
Possible cause:
Checked again. ubuntu@ip-10-10-10-187:/usr/lib/zabbix/externalscripts$ zabbix_server --version zabbix_server (Zabbix) 4.0.1 Revision 86073 29 October 2018, compilation time: Oct 29 2018 17:49:36
This script is working properly from console: ubuntu@ip-10-10-10-187:/usr/lib/zabbix/externalscripts$ sudo ./zaws-linux-amd64 "ec2" "list" "-r=us-east-1" "-k=mykey" "-s=mysecretkey" So the result is a big output in console with right aws names, IP addresses etc, like this (this is just a part part): { "data": [{ "{#INSTANCE.NAME}": "AWS Instance Name", "{#INSTANCE.TYPE}": "t2.micro", "{#INSTANCE.ID}": "i-AWSID", "{#INSTANCE.PRIVATE.ADDR}": "10.10.10.59" }, { "{#INSTANCE.NAME}": "AWS Instance Name 2", "{#INSTANCE.TYPE}": "t2.large", "{#INSTANCE.ID}": "i-AWSID", "{#INSTANCE.PRIVATE.ADDR}": "10.100.102.47" }] } When I'm checking this output with any online JSON validator, for example https://jsonlint.com/ - I'm getting "Valid JSON" result. But issue as mentioned before that I'm getting 'Value should be a JSON object' on 'Discovery rules' page. There is no AWS API connection errors.
Thanks.
Thanks! I checked your response json. I think your json format is valid. This command can be executed by Zabbix process user?
Hi Ike,
Trying to configure zaws plugin in zabbix 3.4, but get 'Value should be a json object' on 'Discovery rules' page. Could you help to find and solve the root cause? Thanks!