首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 其他教程 > 操作系统 >

(转)测试网页响应时间的shell脚本[急需curl支持]

2012-07-03 
(转)测试网页响应时间的shell脚本[需要curl支持]用法及返回结果如下:lvyaozu@lvyaozu-desktop:~/shell$ ./

(转)测试网页响应时间的shell脚本[需要curl支持]

用法及返回结果如下:
lvyaozu@lvyaozu-desktop:~/shell$ ./requesturl.sh -n20 http://www.baidu.com
Request url: http://www.baidu.com
Request number: 20
Request Failed: 0
——Average Value——
time_connect: 0.1614
time_total: 0.1693
time_namelookup: 0.0088
————————-
请求参数:
-n 指定发送多少次请求,默认为10

返回结果为 curl -w 选项返回值,以下摘自curl官方文档:

http://curl.haxx.se/docs/manpage.html

time_connect The time, in seconds, it took from the start until the TCP connect to the remote host (or proxy) was completed.
time_total The total time, in seconds, that the full operation lasted. The time will be displayed with millisecond resolution.
time_namelookup The time, in seconds, it took from the start until the name resolving was completed.

?

?

?

?

?

?

?

?

热点排行