Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: ZFS, BTRFS Volume monitoring by amon agent #202

Open
DerDanilo opened this issue Jan 30, 2018 · 7 comments
Open

Feature request: ZFS, BTRFS Volume monitoring by amon agent #202

DerDanilo opened this issue Jan 30, 2018 · 7 comments

Comments

@DerDanilo
Copy link

It would be great if the amon agent can monitor ZFS and BTRFS pools and if it could also monitor the state of such pools.

@martinrusev
Copy link
Member

@DerDanilo You can do that right now with this plugin: https://github.com/sensu-plugins/sensu-plugins-zfs

@DerDanilo
Copy link
Author

DerDanilo commented Jan 30, 2018

I followed the guide and got the following error:

root@host:/opt/amonagent# echo '["metrics-iostat-extended.rb"]' > /etc/opt/amonagent/plugins-enabled/sensu.conf
root@host:/opt/amonagent# echo '["check-zpool.rb"]' >> /etc/opt/amonagent/plugins-enabled/sensu.conf
root@host:/opt/amonagent# systemctl restart amonagent
root@host:/opt/amonagent# /opt/amonagent/amonagent -test-plugin=sensu
ERRO[0000] Can't decode JSON file                        error=invalid character '[' after top-level value plugin=sensu
map[]

I have had the same with nagios plugins. When defining multiple plugins how to define them? List or array? Can you make an example in your documentation.

Update: Did I just miss reading the part regarding the list of config files or was it added just now?

@martinrusev
Copy link
Member

@DerDanilo Something I definitely need to make much clearer - Amon supports Sensu plugins in 2 place. First - we have metrics plugins, which send metric data and these are processes in the sensu plugin and then we have checks, which cover both Nagios and Sensu health check type of plugins - these generate CRITICAL / WARNING / OK statuses

What I see from the error above is maybe some sort of typo in the JSON config, but not 100%, can you /etc/opt/amonagent/plugins-enabled/sensu.conf?

@DerDanilo
Copy link
Author

Thanks for that info. Now they appear in the health check overview.
As you said already it would be good to make the difference between Metrics/Checks clear.

Do you have a useful overview for metrics vs check plugins? I am new to ruby code.

@martinrusev
Copy link
Member

@DerDanilo At least in sensu you can differentiate them by the name: this is how checks look like bin/check-mongodb.rb and the metrics are bin/metrics-mongodb.rb. Nagios is 100% check plugins

@ghost
Copy link

ghost commented Feb 1, 2018

Maybe it's also useful to mention the default path for sensu metrics and check files. Have had to search them first. Thanks though.

@martinrusev
Copy link
Member

@dschwabeS11 The default path is not consistent across distros - it is different with the embedded Sensu Ruby install, on CentOS and Ubuntu/Debian

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants