1、环境搭建
2、修改配置文件:apache服务搭建参照之前文章:http://blog.csdn.net/weilan100/article/details/51077311(本次采用rpm自动安装版)
下载webpagetest安装文件,cp服务端文件到apache的DocumentRoot下
检查需要包安装情况
php (需要libxml2包)php --ini查看本机php服务安装目录
需要的apache模板组件 apache安装目录下的modules/libphp5.so
添加加载模板组件 LoadModule php5_module modules/libphp5.so
添加使用php服务 PHPIniDir "/usr/local/lib" (查找php安装目录 php --ini php.ino文件位置)
#解析php文件<FilesMatch \.php$>
SetHandler application/x-httpd-php
</FilesMatch>
<FilesMatch "\.ph(p[2-6]?|tml)$">
SetHandler application/x-httpd-php
</FilesMatch>
增加index文件:index.php index.php3
3、agent配置信息
server端:将webpagetest/settings目录下的sample文件拷贝一份去掉.sample
修改 webpagetest/settings/locations.ini
agent端:wptdriver.ini.sample cp为wptdriver.ini 修改url地址&&location字段
location.ini(二级目录) 与 wptDriver.ini 的 location========================[locations]1=local-WPTDriverdefault=local-WPTDriver; These are the top-level locations that are listed in the location dropdown; Each one points to one or more browser configurations[local-WPTDriver]1= locallabel="local-WPTDriver"group=Public; Tese are the browser-specific configurations that match the configurations; defined in the top-level locations. Each one of these MUST match the location; name configured on the test agent (urlblast.ini or wptdriver.ini)==================================
4、文档目录
log文件:webpagetest/logs
5、排查问题
查看php部署参数:
<?
phpinfo();
?>
查看webpagetest部署情况:http://ip:port/install/
查看agent链接情况:http://ip:port/?hidden=1(排除server的agent配置问题)
6、具体使用
Q&A参照之前上传文档:http://wenku.baidu.com/view/e0ffe9e4e2bd960590c677d8
1、只显示文字 没有样式 只是访问到文件目录
错误信息:/var/www/html/js, referer: http://192.168.117.97:8080/webpagetest/
File does not exist: /var/www/html/js, referer: http://192.168.117.97:8080/webpagetest/
File does not exist: /var/www/html/images, referer: http://192.168.117.97:8080/webpagetest
修改 DocumentRoot "/var/www/html/webpagetest" 为webpagetest下 ,webpagetest中的js、css等文件是基于documentroot目录来查找。