httpserver.logとログファイルフォーマット
□未翻訳
□翻訳中
□翻訳完了(Yota Ichino)
■レビュー(Omi Chiba)
httpserver.logとログファイルフォーマット
web2pyのwebサーバーはファイルへのリクエストをweb2pyのルートディレクトに置かれている:
The web2py web server logs all requests to a file called:
へ全て記録します。ファイル名やロケーションをweb2pyのコマンドラインオプションを使い指定できます。
in the root web2py directory. An alternative filename and location can be specified via web2py command-line options.
新しいエントリーは、リクエストが処理されるたびにファイル末尾へ追加されます。それぞれの行はこのようになります:
New entries are appended to the end of the file each time a request is made. Each line looks like this:
フォーマットは:
The format is:
1.
ip, timestamp, method, path, protocol, status, time_taken
各要素について
Where
ipはリクエストしてきたクライアントのIPアドレス
ip is the IP address of the client who made the request
timestampはリクエストの日付と時間、ISO8601フォーマット(YYYY-MM-DDT HH:MM:SS)で記述
timestamp is the date and time of the request in ISO 8601 format, YYYY-MM-DDT HH:MM:SS
methodはPOSTかGETのどちらか
method is either GET or POST
pathはクライアントがリクエストしたパス
path is the path requested by the client
protocolはクライアントへの送信に使用されたHTTPプロトコル、たいていはHTTP/1.1
protocol is the HTTP protocol used to send to the client, usually HTTP/1.1
statusはHTTPのステータスコード91
status is the one of the HTTP status codes 91
time_takenはサーバーがリクエストプロセスに掛けた時間の統計、単位は秒、アップロード/・ダウンロードにかかる時間は含まれません
time_taken is the amount of time the server took to process the request, in seconds, not including upload/download time.
アプリケーションのリポジトリ 34から、ログ解析のアプリケーションを利用できます。
In the appliances repository 34 , you will find an appliance for log analysis.
このロギングは、mod_wsgi使用時にログがApacheログと同じになるため、デフォルトでは有効になりません。
This logging is disabled by default when using mod_wsgi since it would be the same as the Apache log.