一、开启apache的server status。
在Apache配置文件httpd.conf中找到#LoadModule status_module modules/mod_status.so与#Include conf/extra/httpd-info.conf,去掉前边#加载模块。
二、extra/httpd-info.conf文件中对应地方修改:
第一处:
# Change the ".example.com" to match your domain to enable.
<Location /server-status>
SetHandler server-status
Order deny,allow
Deny from all
Allow from all
</Location>
第二处:
#ExtendedStatus On
去掉#ExtendedStatus On前边#,加载模块
第三处:
# Change the ".example.com" to match your domain to enable.
#
< Location /server-info>
SetHandler server-status
Order deny,allow
Deny from all
Allow from all
</Location>
三、说明
1、<Location /server-info>:
server-info:域名后面加server-info查看mod_stutas数据。
2、Allow from all:
all代表所有域名,可以指定单纯的域名。