To check the current status of an Apache server, you’d usually use the log files. But there’s another way of checking the same. You can create a web page that’d display the status. You can visit this page and see if the Apache server is working as intended.
First, you need to add codes to the httpd.conf file. So open the file and add the following codes:
Now restart the Apache server using:
Now open the browser window. You should see the following parameters:
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.
Take note of the IP address from above. From the IP address, visit the below URL:
https://your-apache-configured-web-server.com/server-status
It will display all the data related to the Apache server performance you need to know.
You can also get updated Apache server status automatically after a few seconds using this command
https://your-apache-configured-web-se…atus?refresh=N
Replace N with the number of seconds. So that’s how you create a page to display Apache server information.
First, you need to add codes to the httpd.conf file. So open the file and add the following codes:
Code:
ExtendedStatus On
<Location /server-status>
SetHandler server-status
Deny from all
Order deny,allow
Allow from localhost 192.168,1,56
Allow from .anotherdomain.com
</Location>
Code:
/etc/init.d/apache2 restart
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.
Take note of the IP address from above. From the IP address, visit the below URL:
https://your-apache-configured-web-server.com/server-status
It will display all the data related to the Apache server performance you need to know.
You can also get updated Apache server status automatically after a few seconds using this command
https://your-apache-configured-web-se…atus?refresh=N
Replace N with the number of seconds. So that’s how you create a page to display Apache server information.