How to View Apache Server Status Page

Monitoring your web server’s health is crucial for maintaining optimal performance and troubleshooting sudden traffic spikes. This article provides a straightforward guide on how to enable and view the Apache HTTP Server status page using the mod_status module. You will learn how to configure the module in your server files, secure access to authorized users, and interpret the real-time metrics displayed on the status dashboard.


Step 1: Enable the mod_status Module

Before you can view the status page, you need to ensure that the mod_status module is enabled on your Apache server. On most modern Linux distributions, this module is enabled by default.

Step 2: Configure Access in Apache

For security reasons, you must restrict who can view the server status page, as it exposes sensitive information about your server’s operation and active connections. You will need to edit your Apache configuration file (such as /etc/apache2/mods-enabled/status.conf on Debian or /etc/httpd/conf.d/server-status.conf on RHEL).

Add or modify the configuration block to look like this:

<Location "/server-status">
    SetHandler server-status
    Require local
    # To allow remote access from a specific IP, uncomment the line below:
    # Require ip your_local_ip_address
</Location>

Using Require local ensures that only requests originating from the server itself can access the page. If you need to monitor the server remotely, replace your_local_ip_address with your actual public or VPN IP address.

Step 3: Enable Extended Status (Optional)

By default, Apache only provides a basic summary. If you want full tracking information—including CPU usage, bytes per second, and the exact requests currently being processed—you should enable the ExtendedStatus directive.

Add the following line outside of the <Location> block in your configuration file:

ExtendedStatus On

Step 4: Restart the Apache Service

For any configuration changes to take effect, you must restart your Apache web server. Use the appropriate command for your operating system:

Step 5: Access the Status Page

Once the server restarts, you can view the live status page through a web browser or the command line.

To get a automatically refreshing version of the page, you can append ?refresh=N to the URL, where N is the number of seconds between updates (for example, http://localhost/server-status?refresh=5).