开发者

Measuring traffic sent received

I'm using WAMP.

I want to measure the bytes sent and received while viewing the project.

How 开发者_StackOverflow社区to do so ?


Clientside solution: If you are using firefox, the addon firebug ( https://addons.mozilla.org/de/firefox/addon/firebug/ ) can do this.

Serverside solution: You can specify the following in your apache log format (for your access log):

%...B:          Bytes sent, excluding HTTP headers.
%...b:          Bytes sent, excluding HTTP headers. In CLF format

The "..." can be nothing at all (e.g., "%h %u %r %s %b"), or it can indicate conditions for inclusion of the item (which will cause it to be replaced with "-" if the condition is not met).

See: http://httpd.apache.org/docs/1.3/mod/mod_log_config.html

Addition: You will find something like this in your httpd.conf:

 LogFormat "%h %l %u %t \"%r\" %>s %b" common
 CustomLog logs/access_log common

which is easy to customize.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜