I am trying to get mod_status set up on my apache 2.4 server. I have trawled the net for hours but all the examples given just show the tags in the main httpd.conf file, not how to place the directives into a virtual host setup.
This is my virtual host config with what I have tried. When I do this and then open a local browser or a browser from my allowed ip address (my remote public address) I get a forbidden error in the browser.
<VirtualHost *:80>
ServerName www.thevmscloud.com
ServerAlias thevmscloud.com
ServerAdmin [email protected]
DocumentRoot "d:/wamp/webdocs/www/"
ErrorLog "logs/www.thevmscloud.com.log"
CustomLog "logs/www.thevmscloud.com.log" common
<Location /server-status>
SetHandler server-status
Order deny,allow
Deny from all
Require host 127.0.0.1 81.133.136.16
</Location>
<Directory "d:/wamp/webdocs/www/">
LogLevel crit
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride all
Order Allow,Deny
Allow from all
Require all granted
</Directory>
I have tried all manner of different combinations of settings commented in/out, location block with the virtual host block, outside it, in the httpd.conf main body and still no joy.
Trouble is, I just cant find an example of this setup anywhere. Some posts say 'you might want to add this to you virtual host config' but then dont show how.
Does anybody have any idea how this is to be configured so I can browse to my domain.com/server-status and see the server stats as expected?
Many thanks Mark
Change it to this:
<Location /server-status>
SetHandler server-status
Require ip 127.0.0.1
Require ip ::1
Require ip 81.133.136.16
</Location>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With