ログファイルからユーザーエージェントを読み取って抽出するためのバッチファイルを作成しようとしていますが、これは次のコードで実行できますが、リクエストを作成したブラウザーの数値を指定する必要があり、gnu-plot を使用してプロットしますブラウザごとのリクエスト数の棒グラフ。ブラウザのリクエストに行き詰まっています。少し助けや指示をいただければ幸いです。
乾杯。
#!/bin/bash
# All we're doing here is extracting the user agent field from the log file and 'piping' it through some other commands. The first sort is to # enable uniq to properly identify and count unique user agents. The final sort orders the result by number and name (both descending).
awk -F\" '{print $6}' access.log | sort | uniq -c | sort -fr > extracteduseragents.txt