I have a simple check on nagios like this...HOURS=2SECONDS=$(expr $HOURS \* 60 \* 60)OHAI_TIME="$(expr $(date +%s) - $SECONDS)"SEARCH="$(knife search node "ohai_time:[* TO $OHAI_TIME] AND chef_environment:production")"...--On Wed, Sep 17, 2014 at 3:35 PM, DV < " target="_blank"> > wrote:We have a custom Rails app that acts as handler for chef-client. Here's what dashboard looks like: http://i.imgur.com/sR4UCWC.pngWe also have an automated task that runs "knife status" and reports on any hosts that haven't checked in for a while.--On Wed, Sep 17, 2014 at 9:37 AM, Mark Mzyk < " target="_blank"> > wrote:The report handler that supplies the data from the client run to the Chef server reporting add on is open source, so it could be used and/or built off of, if you didn't want to use the pre-built Chef add ons.
It's here in the client: https://github.com/opscode/chef/blob/master/lib/chef/resource_reporter.rb
- Mark Mzyk
Jumping into the "we do.." postings: We send chef-client statistics to
zabbix using a report handler:
- success
- elapsed_time
- start_time
- end_time
- all_resources_num
- updated_resource num
I think that should be pretty easy to adapt to whatever monitoring
system you use.
Yours
Steffen
Links:
https://github.com/TYPO3-cookbooks/zabbix-custom-checks/blob/master/recipes/chef-client.rb
https://github.com/TYPO3-cookbooks/zabbix-custom-checks/blob/master/templates/default/chef-client/chef-client-handler.rbWhat are people using to monitor and measure their chef-client runs?I would like to monitor for when chef-client runs fail on a node.It would be nice to measure chef-client run times.Is it safe to assume people are using handlers for both of these? What are some popular ways to accomplish these goals? Thanks!
Best regards, Dmitriy V.
-- Tiago Cruz
Archive powered by MHonArc 2.6.16.