Created
October 25, 2013 18:47
-
-
Save drusellers/7159795 to your computer and use it in GitHub Desktop.
iis and logstash
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
input { | |
stdin {} | |
file { | |
type => "iis" | |
path => "C:/inetpub/logs/LogFiles/W3SVC*/*.log" | |
} | |
} | |
filter { | |
if [message] =~ "^#" { | |
drop {} | |
} | |
#http://grokdebug.herokuapp.com/ | |
grok { | |
match => ["message", "%{DATESTAMP:log_timestamp} %{IPORHOST:site} %{WORD:method} %{URIPATH:path} %{NOTSPACE:querystring} %{NUMBER:port} %{NOTSPACE:username} %{IPORHOST:clienthost} %{NOTSPACE:useragent} %{NUMBER:response} %{NUMBER:subresponse} %{NUMBER:scstatus} %{NUMBER:timetaken}"] | |
} | |
} | |
output { | |
elasticsearch { embedded => true } | |
stdout { codec => rubydebug } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment