{"id":68,"date":"2009-05-14T11:20:04","date_gmt":"2009-05-14T16:20:04","guid":{"rendered":"http:\/\/somethingdoug.com\/thoughts\/2009\/05\/14\/new-check_over_http-features\/"},"modified":"2009-05-14T11:21:54","modified_gmt":"2009-05-14T16:21:54","slug":"new-check_over_http-features","status":"publish","type":"post","link":"https:\/\/somethingdoug.com\/thoughts\/2009\/05\/14\/new-check_over_http-features\/","title":{"rendered":"New check_over_http features"},"content":{"rendered":"<p>Yesterday I finished up some more features to <a href=\"http:\/\/search.cpan.org\/dist\/Nagios-Plugin-OverHTTP\/\">Plugin::Nagios::OverHTTP<\/a>. Before the only parameter that could be passed was <span style=\"font-family: Courier New;\">url<\/span>. Now this parameter can still be passed, but you may also pass other individual parameters, including <span style=\"font-family: Courier New;\">hostname<\/span>, <span style=\"font-family: Courier New;\">path<\/span>, and <span style=\"font-family: Courier New;\">ssl<\/span>. This helps improve the check_over_http utility which would be used in the Nagios checking. Typically the command definition would have been something like the following:<\/p>\n<pre>define command{\r\n        command_name check_over_http\r\n        command_line check_over_http --url=$ARG1$ $ARG2$\r\n        }<\/pre>\n<p>This means the following would need to be in a service definition:<\/p>\n<pre>define service{\r\n        use                            noncritical-service\r\n\r\n        host_name                      server1\r\n        service_description            Connection to MySQL\r\n        notes                          Checks if the server can connect to remote MySQL\r\n        check_command                  check_over_http!http:\/\/server1\/nagios\/check_remote_mysql\r\n        }<\/pre>\n<p>As you can see, the check command duplicates the hostname, which is not the way of Nagios plugins. Now With version 0.04 and up, we can have the following definitions:<\/p>\n<pre>define command{\r\n        command_name check_over_http\r\n        command_line check_over_http --hostname=$HOSTADDRESS$ --path=$ARG1$ $ARG2$\r\n        }<\/pre>\n<pre>define service{\r\n        use                            noncritical-service\r\n\r\n        host_name                      server1\r\n        service_description            Connection to MySQL\r\n        notes                          Checks if the server can connect to remote MySQL\r\n        check_command                  check_over_http!\/nagios\/check_remote_mysql\r\n        }<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Yesterday I finished up some more features to Plugin::Nagios::OverHTTP. Before the only parameter that could be passed was url. Now this parameter can still be passed, but you may also pass other individual parameters, including hostname, path, and ssl. This helps improve the check_over_http utility which would be used in the Nagios checking. Typically the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[12,21,27,19],"class_list":["post-68","post","type-post","status-publish","format-standard","hentry","category-perl","tag-cpan","tag-nagios","tag-perl","tag-perl5"],"_links":{"self":[{"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/posts\/68","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/comments?post=68"}],"version-history":[{"count":2,"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/posts\/68\/revisions"}],"predecessor-version":[{"id":69,"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/posts\/68\/revisions\/69"}],"wp:attachment":[{"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/media?parent=68"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/categories?post=68"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/somethingdoug.com\/thoughts\/wp-json\/wp\/v2\/tags?post=68"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}