Check_apache_requests

Introduction


CHECK_APACHE_REQUESTS v1.5

(c) Institute for Medical Education - University of Bern Licence: GNU GPL 3


Get Apache httpd server-status page localhost/server-status. You get output with the server status and values for each slot type.

The plugin sends performance data for

  • each slot type
  • active, idle, unused slots

The response is UNKNOWN if url was not reached within 5 seconds or if the response does not contain a scoreboard.

You get a WARNING if the count of used slots (excluding idle and unused slots) is greater 75% of available slots. You get an CRITICAL response if it is greater 90% of available slots.

Slot types of apache httpd: _ Waiting for Connection, S Starting up, R Reading Request W Sending Reply, K Keepalive (read), D DNS Lookup C Closing connection, L Logging, G Gracefully finishing I Idle cleanup of worker . Open slot with no current process

Syntax

check_apache_requests [-w WARN_LIMIT] [-c CRITICAL_LIMIT]

OPTIONS:

    -w VALUE       warning level  (default: 75)
    -c VALUE       critical level (default: 90)

    -h or --help   show this help.

PARAMETERS:

    None.

Examples

check_apache_requests

check_apache_requests -w 60 -c 80

Output example:

OK: Apache: 10000 slots ...  active: 1  wait: 524  unused: 9475 (0 % usage)
Server MPM: event
Server Built: Apr  6 2022 14:54:37
Current Time: Wednesday, 31-Aug-2022 15:09:31 CEST
Restart Time: Monday, 11-Jul-2022 05:07:15 CEST
Parent Server Config. Generation: 52
Parent Server MPM Generation: 51
Server uptime:  51 days 10 hours 2 minutes 16 seconds
Server load: 0.83 0.83 0.82
Total accesses: 3368214 - Total Traffic: 44.1 GB - Total Duration: 258025460
CPU Usage: u650.56 s621.39 cu55050.6 cs32047.5 - 1.99% CPU load
.758 requests/sec - 10.4 kB/second - 13.7 kB/request - 76.606 ms/request
1 requests currently being processed, 524 idle workers

Slots:
  - S: 0
  - R: 0
  - W: 1
  - K: 0
  - D: 0
  - C: 0
  - L: 0
  - G: 0
  - I: 0
  - _: 524
  - .: 9475
 |apache-active=1;;;0;10000 apache-s=0;;;0;10000 apache-r=0;;;0;10000 apache-w=1;;;0;10000 apache-k=0;;;0;10000 apache-d=0;;;0;10000 apache-c=0;;;0;10000 apache-l=0;;;0;10000 apache-g=0;;;0;10000 apache-i=0;;;0;10000 apache-idle=524;;;0;10000 apache-unused=9475;;;0;10000 

Graph

See https://git-repo.iml.unibe.ch/iml-open-source/icinga-graphite-templates