Server Monitoring2 min read

    How to Monitor Apache Web Server

    By DanaServer Monitoring & Linux
    Share

    Overview

    The Apache integration allows you to monitor your Apache HTTP web server performance in real time using the mod_status module. Once activated, Xitoring collects key metrics like request processing times, server load, bandwidth usage, and connection states — all visible from your dashboard.

    What Can It Monitor?

    The Apache integration tracks the following metrics:

    • Load 1 / Load 5 / Load 15 — Server load averages over 1, 5, and 15 minutes
    • Requests per Second — Rate of incoming HTTP requests
    • Bytes per Second — Data throughput rate
    • Bytes per Request — Average response size per request
    • Busy Workers — Number of worker threads actively processing requests
    • Idle Workers — Number of worker threads waiting for requests
    • Total Accesses — Cumulative request count since server start
    • Total kBytes — Total data served since server start
    • Uptime — How long the Apache server has been running

    Prerequisites

    Before enabling the integration, you need to ensure that mod_status is enabled on your Apache server.

    On Debian-based OS (Ubuntu, Debian)

    Check if mod_status is enabled:

    ls /etc/apache2/mods-enabled | grep status*
    

    You should see status.conf and status.load in the output. Then edit /etc/apache2/mods-enabled/status.conf:

    <IfModule mod_status.c>
        <Location /server-status>
            SetHandler server-status
            Require local
        </Location>
        ExtendedStatus On
        <IfModule mod_proxy.c>
            ProxyStatus On
        </IfModule>
    </IfModule>
    

    Restart Apache after making changes:

    sudo systemctl restart apache2
    

    On RHEL-based OS (CentOS, AlmaLinux, Rocky)

    Verify mod_status is available:

    ls -al modules/ | grep status*
    

    Add the following to /etc/httpd/conf/httpd.conf:

    <IfModule mod_status.c>
        ExtendedStatus On
        <Location /server-status>
            SetHandler server-status
            Require local
        </Location>
    </IfModule>
    

    Restart Apache:

    sudo systemctl restart httpd
    

    On Windows Server

    Open httpd.conf (typically at C:\Program Files\Apache Group\Apache2\conf\httpd.conf) and ensure this line is not commented out:

    LoadModule status_module modules/mod_status.so
    

    How to Activate the Integration

    Once mod_status is configured, activate the integration via the Xitogent CLI:

    xitogent integrate
    

    Select Apache from the list of available integrations. When prompted, enter the URL where Apache serves its status page (e.g., http://127.0.0.1/server-status).

    The integration config file will be created at /etc/xitogent/integrations/apache_integration.conf.

    Setting Up Triggers

    You can create custom triggers to get alerted when any metric exceeds or drops below a threshold. Available trigger parameters include:

    • Load 1, Load 5, Load 15
    • Requests per Second
    • Bytes per Second
    • Bytes per Request
    • Busy Workers / Idle Workers
    • Total Accesses / Total kBytes
    • Uptime

    Navigate to Triggers in your server page, select Apache as the integration, choose the metric, set your threshold, and configure your notification channels.

    Tips

    • Always use ExtendedStatus On to get detailed metrics
    • Restrict the /server-status endpoint to localhost for security
    • Use trigger alerts for Busy Workers to detect capacity issues early
    • Pair with uptime monitoring for complete web server visibility