From 3df0e3a86d6cfe22b4ff47db98a96f346308f38c Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Fri, 28 Jan 2022 10:03:30 +0000 Subject: add stats script --- openbsd/frontends/scripts/httpdstats.sh | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 openbsd/frontends/scripts/httpdstats.sh diff --git a/openbsd/frontends/scripts/httpdstats.sh b/openbsd/frontends/scripts/httpdstats.sh new file mode 100644 index 0000000..892cf22 --- /dev/null +++ b/openbsd/frontends/scripts/httpdstats.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +zgrep -h . /var/www/logs/access.log* | perl -l -n -e '@s=split / +/; next if @s!=11; $s[4]=~s|\[(\d\d)/(...)/(\d{4}):(.*)|$1 $2 $3 $4|; print join " ",@s[0,1,4,7];' -- cgit v1.2.3