How would anyone approach importing multiple Apache2 access logs?
I've tried to add the flag --add-sites-new-hosts but it couln't figure out the virtual hostname.
So i went to edit the Logformat from:
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %b" common
To:
LogFormat "%h %l %u %t %{Host}i \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %b" common
Which will output the following:
dev.local 10.0.0.1 - - [10/Oct/2018:12:31:13 +0200] dev.local "GET / HTTP/1.1" 200 3264 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:62.0) Gecko/20100101 Firefox/62.0"
But it throws:
0 requests imported successfully 0 requests were downloads 23 requests ignored: 0 HTTP errors 0 HTTP redirects 23 invalid log lines
How would anyone approach importing multiple Apache2 access logs? I've tried to add the flag
--add-sites-new-hosts
but it couln't figure out the virtual hostname. So i went to edit the Logformat from:LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %b" common
To:LogFormat "%h %l %u %t %{Host}i \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %b" common
Which will output the following:
dev.local 10.0.0.1 - - [10/Oct/2018:12:31:13 +0200] dev.local "GET / HTTP/1.1" 200 3264 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:62.0) Gecko/20100101 Firefox/62.0"
But it throws:
0 requests imported successfully 0 requests were downloads 23 requests ignored: 0 HTTP errors 0 HTTP redirects 23 invalid log lines