I'm running an ELK stack and passing all my windows logs to it from nxlog, and am having an issue specifically with IIS logs. In nxlog I'm running this in the nxlog.conf file
<Extension w3c>
Module xm_csv
Fields $date, $time, $s-ip, $cs-method, $cs-uri-stem, $cs-uri-query, $s-port, $cs-username, $c-ip, $csUser-Agent, $sc-status, $sc-substatus, $sc-win32-status, $time-taken
FieldTypes string, string, string, string, string, string, string, string, string, string, string, string, string, string
Delimiter ' '
UndefValue -
</Extension>
I'm not running any parsing logstash, and when they show up in elasticsearch / kibana I get this giant message output,
{"message":"2015-10-19 22:17:26 10.10.10.10 GET javascriptScript.js - 443 - 10.10.10.10 Mozilla/4.0+(compatible;+MSIE+7.0;+Windows+NT+6.1;+WOW64;+Trident/7.0;+SLCC2;+.NET+CLR+2.0.50727;+.NET4.0C;+.NET4.0E;+.NET+CLR+3.5.30729;+.NET+CLR+3.0.30729) 200 0 0 31\r","@version":"1","@timestamp":"2015-10-19T22:19:08.061Z","host":"10.10.10.10","type":"WindowsEventLog","tags":["_jsonparsefailure"]}
I want to be able to parse this message, and get all the relevant data out. It seems like it should be possible to parse the iis log through nxlog and then pass the json information through to elasticsearch. But I'm not sure if this is something that I should be doing on the nxlog side, or logstash side. Everything I've looked at is using the same w3c extension, but there isn't a ton of data that I can look at using both nxlog and logstash to parse IIS logs.