Thanks for the response!
The tail end of my /var/log/graylog-server/server.log
has many lines as follows (actual hostname replaced with servername.domain for confidentiality):
...[20]: index [graylog_0], type [_doc], id [2a2fad82-28b6-11ed-88a5-0050568bf8a1], message [ElasticsearchException[Elasticsearch exception [type=mapper_parsing_exception, reason=failed to parse field [cs-host] of type [long] in document with id '2a2fad82-28b6-11ed-88a5-0050568bf8a1'. Preview of field's value: 'servername.domain']]; nested: ElasticsearchException[Elasticsearch exception [type=illegal_argument_exception, reason=For input string: "servername.domain"]];]
Disclaimer: I am a newb at this. There was another guy who did most of the setup for the previous graylog instance, with me mostly observing over his shoulder.
But the above error suggests to me either that the nxlog conf isn’t correct, or that there was someplace else in the elasticsearch or graylog where I was supposed to define the input format.
I’m using NXLog CE 3.0.228
Here’s the nxlog conf formatting section:
#######################################################################
#### IIS NXLOG ######
#######################################################################
<Extension w3c>
Module xm_csv
Fields $date, $time, $s-sitename, $s-computername, $s-ip, $cs-method, $cs-uri-stem, $cs-uri-query, $s-port, $cs-username, $c-ip, $cs-version, $cs_User_Agent, $cs_Cookie, $cs_Referer, $cs-host, $sc-status, $sc-substatus, $sc-win32-status, $sc-bytes, $cs-bytes, $time-taken, $x-forwarded-for,
FieldTypes string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string, string
Delimiter ' '
EscapeChar '"'
QuoteChar '"'
EscapeControl FALSE
UndefValue -
</Extension>
Does that appear to be the standard/default IIS log format?
Since (as far as I know) I’m using the same nxlog conf which worked before, could the format of the IIS logs have changed?
EDIT: I realized I forgot to add the Input config you asked for:
Editing Input Production Environment IIS Logs
Global
Should this input start on all nodes
Title
Production Environment IIS Logs
Bind address
0.0.0.0
Address to listen on. For example 0.0.0.0 or 127.0.0.1.
Port
12203
Port to listen on.
Receive Buffer Size (optional)
262144
The size in bytes of the recvBufferSize for network connections to this input.
No. of worker threads (optional)
16
Number of worker threads processing network connections for this input.
Override source (optional)
The source is a hostname derived from the received packet by default. Set this if you want to override it with a custom string.
Decompressed size limit (optional)
8388608
The maximum number of bytes after decompression.