Re: [Nagios-users] check_http 1.4.15
Scott, Did you read my answer at all (Feb 27th)? You're looking for something that hasn't been implemented. Here again the post: The link you posted is a user-contributed patch for check_http, posted on the tracker on Jan 3rd 2012. Nagios Plugins v. 1.4.15 were released in July 2010 so you can be sure that this patch has not made it into 1.4.15. You have two options: - Wait and hope that this patch will make it sometime into the branch and next version release (good luck with that) - Re-compile check_http from source with the patch yourself - ck On Wed, Feb 29, 2012 at 11:38 PM, Werner, Robert rwer...@pomwonderful.comwrote: Can you include the command line you are using and what you expect it to do? ** ** -- Robert G. Werner Oracle Apps Systems Administrator rwer...@pomwonderful.com 559.521.5089 ** ** *From:* Scott Ford [mailto:sm_f...@yahoo.com] *Sent:* Tuesday, February 28, 2012 12:03 PM *To:* nagios-users@lists.sourceforge.net *Subject:* [Nagios-users] check_http 1.4.15 ** ** All, I installed Nagios Plugins v.1.4.15 after reading a post on Sourceforge that showed the latest version of check_http included an option for regular expression searches in the header of the file. That option does not seem to be available. Can anyone shed some light on this? This is the post I read... ** ** http://sourceforge.net/tracker/index.php?func=detailaid=3469275group_id=29880atid=397599 ** ** Thank you in advance, ** ** Scott ** ** ** ** [sforddev plugins]# ./check_http --help check_http v1.4.15 (nagios-plugins 1.4.15) Copyright (c) 1999 Ethan Galstad nag...@nagios.org Copyright (c) 1999-2008 Nagios Plugin Development Team nagiosplug-de...@lists.sourceforge.net This plugin tests the HTTP service on the specified host. It can test normal (http) and secure (https) servers, follow redirects, search for strings and regular expressions, check connection times, and report on certificate expiration times. Usage: check_http -H vhost | -I IP-address [-u uri] [-p port] [-w warn time] [-c critical time] [-t timeout] [-L] [-a auth] [-b proxy_auth] [-f ok|warning|critcal|follow|sticky|stickyport] [-e expect] [-s string] [-l] [-r regex | -R case-insensitive regex] [-P string] [-m min_pg_size:max_pg_size] [-4|-6] [-N] [-M age] [-A string] [-k string] [-S] [--sni] [-C age] [-T content-type] [-j method] NOTE: One or both of -H and -I must be specified Options: -h, --help Print detailed help screen -V, --version Print version information -H, --hostname=ADDRESS Host name argument for servers using host headers (virtual host) Append a port to include it in the header (eg: example.com:5000) -I, --IP-address=ADDRESS IP address or name (use numeric address if possible to bypass DNS lookup). -p, --port=INTEGER Port number (default: 80) -4, --use-ipv4 Use IPv4 connection -6, --use-ipv6 Use IPv6 connection -e, --expect=STRING Comma-delimited list of strings, at least one of them is expected in the first (status) line of the server response (default: HTTP/1.) If specified skips all other status line logic (ex: 3xx, 4xx, 5xx processing) -s, --string=STRING String to expect in the content -u, --url=PATH URL to GET or POST (default: /) -P, --post=STRING URL encoded http POST data -j, --method=STRING (for example: HEAD, OPTIONS, TRACE, PUT, DELETE) Set HTTP method. -N, --no-body Don't wait for document body: stop reading after headers. (Note that this still does an HTTP GET or POST, not a HEAD.) -M, --max-age=SECONDS Warn if document is more than SECONDS old. the number can also be of the form 10m for minutes, 10h for hours, or 10d for days. -T, --content-type=STRING specify Content-Type header media type when POSTing -l, --linespan Allow regex to span newlines (must precede -r or -R) -r, --regex, --ereg=STRING Search page for regex STRING -R, --eregi=STRING Search page for case-insensitive regex STRING --invert-regex Return CRITICAL if found, OK if not -a, --authorization=AUTH_PAIR Username:password on sites with basic authentication -b, --proxy-authorization=AUTH_PAIR Username:password on proxy-servers with basic authentication -A, --useragent=STRING String to be sent in http header as User Agent -k, --header=STRING Any other tags to be sent in http header. Use multiple times for additional headers -L, --link Wrap output in HTML link (obsoleted by urlize) -f, --onredirect=ok|warning|critical|follow|sticky|stickyport How to handle redirected pages. sticky is like follow but stick to the specified IP address. stickyport also ensure post stays the same. -m, --pagesize=INTEGER:INTEGER Minimum page size required (bytes) : Maximum page size
[Nagios-users] check_http 1.4.15
All, I installed Nagios Plugins v.1.4.15 after reading a post on Sourceforge that showed the latest version of check_http included an option for regular expression searches in the header of the file. That option does not seem to be available. Can anyone shed some light on this? This is the post I read... http://sourceforge.net/tracker/index.php?func=detailaid=3469275group_id=29880atid=397599 Thank you in advance, Scott [sforddev plugins]# ./check_http --help check_http v1.4.15 (nagios-plugins 1.4.15) Copyright (c) 1999 Ethan Galstad nag...@nagios.org Copyright (c) 1999-2008 Nagios Plugin Development Team nagiosplug-de...@lists.sourceforge.net This plugin tests the HTTP service on the specified host. It can test normal (http) and secure (https) servers, follow redirects, search for strings and regular expressions, check connection times, and report on certificate expiration times. Usage: check_http -H vhost | -I IP-address [-u uri] [-p port] [-w warn time] [-c critical time] [-t timeout] [-L] [-a auth] [-b proxy_auth] [-f ok|warning|critcal|follow|sticky|stickyport] [-e expect] [-s string] [-l] [-r regex | -R case-insensitive regex] [-P string] [-m min_pg_size:max_pg_size] [-4|-6] [-N] [-M age] [-A string] [-k string] [-S] [--sni] [-C age] [-T content-type] [-j method] NOTE: One or both of -H and -I must be specified Options: -h, --help Print detailed help screen -V, --version Print version information -H, --hostname=ADDRESS Host name argument for servers using host headers (virtual host) Append a port to include it in the header (eg: example.com:5000) -I, --IP-address=ADDRESS IP address or name (use numeric address if possible to bypass DNS lookup). -p, --port=INTEGER Port number (default: 80) -4, --use-ipv4 Use IPv4 connection -6, --use-ipv6 Use IPv6 connection -e, --expect=STRING Comma-delimited list of strings, at least one of them is expected in the first (status) line of the server response (default: HTTP/1.) If specified skips all other status line logic (ex: 3xx, 4xx, 5xx processing) -s, --string=STRING String to expect in the content -u, --url=PATH URL to GET or POST (default: /) -P, --post=STRING URL encoded http POST data -j, --method=STRING (for example: HEAD, OPTIONS, TRACE, PUT, DELETE) Set HTTP method. -N, --no-body Don't wait for document body: stop reading after headers. (Note that this still does an HTTP GET or POST, not a HEAD.) -M, --max-age=SECONDS Warn if document is more than SECONDS old. the number can also be of the form 10m for minutes, 10h for hours, or 10d for days. -T, --content-type=STRING specify Content-Type header media type when POSTing -l, --linespan Allow regex to span newlines (must precede -r or -R) -r, --regex, --ereg=STRING Search page for regex STRING -R, --eregi=STRING Search page for case-insensitive regex STRING --invert-regex Return CRITICAL if found, OK if not -a, --authorization=AUTH_PAIR Username:password on sites with basic authentication -b, --proxy-authorization=AUTH_PAIR Username:password on proxy-servers with basic authentication -A, --useragent=STRING String to be sent in http header as User Agent -k, --header=STRING Any other tags to be sent in http header. Use multiple times for additional headers -L, --link Wrap output in HTML link (obsoleted by urlize) -f, --onredirect=ok|warning|critical|follow|sticky|stickyport How to handle redirected pages. sticky is like follow but stick to the specified IP address. stickyport also ensure post stays the same. -m, --pagesize=INTEGER:INTEGER Minimum page size required (bytes) : Maximum page size required (bytes) -w, --warning=DOUBLE Response time to result in warning status (seconds) -c, --critical=DOUBLE Response time to result in critical status (seconds) -t, --timeout=INTEGER Seconds before connection times out (default: 10) -v, --verbose Show details for command-line debugging (Nagios may truncate output) Notes: This plugin will attempt to open an HTTP connection with the host. Successful connects return STATE_OK, refusals and timeouts return STATE_CRITICAL other errors return STATE_UNKNOWN. Successful connects, but incorrect reponse messages from the host result in STATE_WARNING return values. If you are checking a virtual server that uses 'host headers' you must supply the FQDN (fully qualified domain name) as the [host_name] argument. Send email to nagios-users@lists.sourceforge.net if you have questions regarding use of this software. To submit patches or suggest improvements, send email to nagiosplug-de...@lists.sourceforge.net-- Virtualization Cloud Management Using Capacity Planning Cloud computing makes use of virtualization - but cloud computing also focuses on
Re: [Nagios-users] check_http 1.4.15
Can you include the command line you are using and what you expect it to do? -- Robert G. Werner Oracle Apps Systems Administrator rwer...@pomwonderful.com 559.521.5089 From: Scott Ford [mailto:sm_f...@yahoo.com] Sent: Tuesday, February 28, 2012 12:03 PM To: nagios-users@lists.sourceforge.net Subject: [Nagios-users] check_http 1.4.15 All, I installed Nagios Plugins v.1.4.15 after reading a post on Sourceforge that showed the latest version of check_http included an option for regular expression searches in the header of the file. That option does not seem to be available. Can anyone shed some light on this? This is the post I read... http://sourceforge.net/tracker/index.php?func=detailaid=3469275group_id=29880atid=397599 Thank you in advance, Scott [sforddev plugins]# ./check_http --help check_http v1.4.15 (nagios-plugins 1.4.15) Copyright (c) 1999 Ethan Galstad nag...@nagios.orgmailto:nag...@nagios.org Copyright (c) 1999-2008 Nagios Plugin Development Team nagiosplug-de...@lists.sourceforge.netmailto:nagiosplug-de...@lists.sourceforge.net This plugin tests the HTTP service on the specified host. It can test normal (http) and secure (https) servers, follow redirects, search for strings and regular expressions, check connection times, and report on certificate expiration times. Usage: check_http -H vhost | -I IP-address [-u uri] [-p port] [-w warn time] [-c critical time] [-t timeout] [-L] [-a auth] [-b proxy_auth] [-f ok|warning|critcal|follow|sticky|stickyport] [-e expect] [-s string] [-l] [-r regex | -R case-insensitive regex] [-P string] [-m min_pg_size:max_pg_size] [-4|-6] [-N] [-M age] [-A string] [-k string] [-S] [--sni] [-C age] [-T content-type] [-j method] NOTE: One or both of -H and -I must be specified Options: -h, --help Print detailed help screen -V, --version Print version information -H, --hostname=ADDRESS Host name argument for servers using host headers (virtual host) Append a port to include it in the header (eg: example.com:5000) -I, --IP-address=ADDRESS IP address or name (use numeric address if possible to bypass DNS lookup). -p, --port=INTEGER Port number (default: 80) -4, --use-ipv4 Use IPv4 connection -6, --use-ipv6 Use IPv6 connection -e, --expect=STRING Comma-delimited list of strings, at least one of them is expected in the first (status) line of the server response (default: HTTP/1.) If specified skips all other status line logic (ex: 3xx, 4xx, 5xx processing) -s, --string=STRING String to expect in the content -u, --url=PATH URL to GET or POST (default: /) -P, --post=STRING URL encoded http POST data -j, --method=STRING (for example: HEAD, OPTIONS, TRACE, PUT, DELETE) Set HTTP method. -N, --no-body Don't wait for document body: stop reading after headers. (Note that this still does an HTTP GET or POST, not a HEAD.) -M, --max-age=SECONDS Warn if document is more than SECONDS old. the number can also be of the form 10m for minutes, 10h for hours, or 10d for days. -T, --content-type=STRING specify Content-Type header media type when POSTing -l, --linespan Allow regex to span newlines (must precede -r or -R) -r, --regex, --ereg=STRING Search page for regex STRING -R, --eregi=STRING Search page for case-insensitive regex STRING --invert-regex Return CRITICAL if found, OK if not -a, --authorization=AUTH_PAIR Username:password on sites with basic authentication -b, --proxy-authorization=AUTH_PAIR Username:password on proxy-servers with basic authentication -A, --useragent=STRING String to be sent in http header as User Agent -k, --header=STRING Any other tags to be sent in http header. Use multiple times for additional headers -L, --link Wrap output in HTML link (obsoleted by urlize) -f, --onredirect=ok|warning|critical|follow|sticky|stickyport How to handle redirected pages. sticky is like follow but stick to the specified IP address. stickyport also ensure post stays the same. -m, --pagesize=INTEGER:INTEGER Minimum page size required (bytes) : Maximum page size required (bytes) -w, --warning=DOUBLE Response time to result in warning status (seconds) -c, --critical=DOUBLE Response time to result in critical status (seconds) -t, --timeout=INTEGER Seconds before connection times out (default: 10) -v, --verbose Show details for command-line debugging (Nagios may truncate output) Notes: This plugin will attempt to open an HTTP connection with the host. Successful connects return STATE_OK, refusals and timeouts return STATE_CRITICAL other errors return STATE_UNKNOWN. Successful connects, but incorrect reponse messages from the host result in STATE_WARNING return values. If you are checking a virtual server that uses 'host headers' you must supply the FQDN (fully qualified domain name) as the [host_name] argument. Send email
Re: [Nagios-users] check_http 1.4.15
Hi Scott, The link you posted is a user-contributed patch for check_http, posted on the tracker on Jan 3rd 2012. Nagios Plugins v. 1.4.15 were released in July 2010 so you can be sure that this patch has not made it into 1.4.15. You have two options: - Wait and hope that this patch will make it sometime into the branch and next version release (good luck with that) - Re-compile check_http from source with the patch yourself On Thu, Feb 23, 2012 at 11:24 PM, Scott Ford sm_f...@yahoo.com wrote: All, I installed Nagios Plugins v.1.4.15 after reading a post on Sourceforge that showed the latest version of check_http included an option for regular expression searches in the header of the file. That option does not seem to be available. Can anyone shed some light on this? This is the post I read... http://sourceforge.net/tracker/index.php?func=detailaid=3469275group_id=29880atid=397599 Thank you in advance, Scott [sforddev plugins]# ./check_http --help check_http v1.4.15 (nagios-plugins 1.4.15) Copyright (c) 1999 Ethan Galstad nag...@nagios.org Copyright (c) 1999-2008 Nagios Plugin Development Team nagiosplug-de...@lists.sourceforge.net This plugin tests the HTTP service on the specified host. It can test normal (http) and secure (https) servers, follow redirects, search for strings and regular expressions, check connection times, and report on certificate expiration times. Usage: check_http -H vhost | -I IP-address [-u uri] [-p port] [-w warn time] [-c critical time] [-t timeout] [-L] [-a auth] [-b proxy_auth] [-f ok|warning|critcal|follow|sticky|stickyport] [-e expect] [-s string] [-l] [-r regex | -R case-insensitive regex] [-P string] [-m min_pg_size:max_pg_size] [-4|-6] [-N] [-M age] [-A string] [-k string] [-S] [--sni] [-C age] [-T content-type] [-j method] NOTE: One or both of -H and -I must be specified Options: -h, --help Print detailed help screen -V, --version Print version information -H, --hostname=ADDRESS Host name argument for servers using host headers (virtual host) Append a port to include it in the header (eg: example.com:5000) -I, --IP-address=ADDRESS IP address or name (use numeric address if possible to bypass DNS lookup). -p, --port=INTEGER Port number (default: 80) -4, --use-ipv4 Use IPv4 connection -6, --use-ipv6 Use IPv6 connection -e, --expect=STRING Comma-delimited list of strings, at least one of them is expected in the first (status) line of the server response (default: HTTP/1.) If specified skips all other status line logic (ex: 3xx, 4xx, 5xx processing) -s, --string=STRING String to expect in the content -u, --url=PATH URL to GET or POST (default: /) -P, --post=STRING URL encoded http POST data -j, --method=STRING (for example: HEAD, OPTIONS, TRACE, PUT, DELETE) Set HTTP method. -N, --no-body Don't wait for document body: stop reading after headers. (Note that this still does an HTTP GET or POST, not a HEAD.) -M, --max-age=SECONDS Warn if document is more than SECONDS old. the number can also be of the form 10m for minutes, 10h for hours, or 10d for days. -T, --content-type=STRING specify Content-Type header media type when POSTing -l, --linespan Allow regex to span newlines (must precede -r or -R) -r, --regex, --ereg=STRING Search page for regex STRING -R, --eregi=STRING Search page for case-insensitive regex STRING --invert-regex Return CRITICAL if found, OK if not -a, --authorization=AUTH_PAIR Username:password on sites with basic authentication -b, --proxy-authorization=AUTH_PAIR Username:password on proxy-servers with basic authentication -A, --useragent=STRING String to be sent in http header as User Agent -k, --header=STRING Any other tags to be sent in http header. Use multiple times for additional headers -L, --link Wrap output in HTML link (obsoleted by urlize) -f, --onredirect=ok|warning|critical|follow|sticky|stickyport How to handle redirected pages. sticky is like follow but stick to the specified IP address. stickyport also ensure post stays the same. -m, --pagesize=INTEGER:INTEGER Minimum page size required (bytes) : Maximum page size required (bytes) -w, --warning=DOUBLE Response time to result in warning status (seconds) -c, --critical=DOUBLE Response time to result in critical status (seconds) -t, --timeout=INTEGER Seconds before connection times out (default: 10) -v, --verbose Show details for command-line debugging (Nagios may truncate output) Notes: This plugin will attempt to open an HTTP connection with the host. Successful connects return STATE_OK, refusals and timeouts return STATE_CRITICAL other errors return STATE_UNKNOWN. Successful connects, but incorrect reponse messages from the host result in