How to setup an apache status page

You can also check and monitor Apache server’s current status on the web page without using

log files. Modify httpd.conf file and add the following code into it:

ExtendedStatus On

SetHandler server-status
Deny from all
Order deny,allow
Allow from localhost 168.125.225.12
Allow from .anotherdomain.com

Restart apache service:

/etc/init.d/apache2 restart

You will see following parameters in the browser window:-

current date and time CPU usage, total uptime, total access made to web server and total traffic. In the same browser page you could able to see PID, scoreboard which tells you about closing connections, logging connections, client’s IP address,load status, VHost name and the request made for particular pages link.

Now you need to enter following URL in the browser from valid IP address mentioned in the above

code i.e. 192.168.1.56 or from localhost or from browser from anotherdomain.com:

http://your-apache-configured-web-se…/server-status

This will give you all the details having apache sever status in the browser window.

If you don’t want to specify domain name in the above code then you can make a comment in front

of it by doing:

# Allow from .anotherdomain.com

You can also use following command to get the apache server status automatically after few seconds:

http://your-apache-configured-web-se…atus?refresh=N

where N is a number of seconds to refresh the status web page.

kbadmin has written 149 articles

Loading Facebook Comments ...

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.