项目背景:
对于我们的web服务器进行数据的实时统计,找一个专门做这件事情的软件来做!
实验环境:
vmware workstation 11
服务器:ip:192.168.0.19 关闭iptables
SecureCRT (ssh远程连接软件)
实验流程:
一:软件安装
我这接用yum进行安装
[root@Varnish-server ~]# yum install apachetop -y
二:软件测试
1:查看帮助项
[root@Varnish-server ~]# apachetop -h
ApacheTop v0.15.6 - Usage:
File options:
-f logfile open logfile (assumed common/combined) [/var/log/httpd/access_log]
(repeat option for more than one source)
URL/host/referrer munging options:
-q keep query strings [no]
-l lowercase all URLs [no]
-s num keep num path segments of URL [all]
-p preserve protocol at front of referrers [no]
-r resolve hostnames/IPs into each other [no]
Stats options:
Supply up to one of the following two. default: [-T 30]
-H hits remember stats for this many hits
-T secs remember stats for this many seconds
-d secs refresh delay in seconds [5]
-h this help
Compile Options: -HAVE_KQUEUE -HAVE_FAM +ENABLE_PCRE
Polling Method: stat
2、启动我们的apche服务
[root@Varnish-server ~]# service httpd start
Starting httpd: httpd: apr_sockaddr_info_get() failed for Varnish-server
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[ OK ]
3、运行apachetop
上面是我在浏览器里打开我的apache服务期以后截的图!
总结: