Hi,
Here is my actual config and output :
filter {
if [type] == "ufdb" {
grok {
match => [ "message", "%{TIMESTAMP_ISO8601:logdate}%{SPACE}%{DATA}%{SPACE}%{WORD:status}%{SPACE}%{USERNAME:group}%{SPACE}%{IP:ip}%{SPACE}%{DATA}%{SPACE}%{WORD:category}%{SPACE}%{URI:url} %{WORD:method}" ]
}
date {
match => [ "logdate", "ISO8601", "YYYY-MM-dd HH:mm:ss" ]
target => "logdate"
locale => "en"
}
mutate {
remove => [ 'file','offset','host' ]
}
}
output on ES :
"hits": {
"total": 8165,
"max_score": 1,
"hits": [
{
"_index": "shit",
"_type": "ufdb",
"_id": "AVBCidxwvfdc1_d4SQML",
"_score": 1,
"_source": {
"message": "2015-11-30 15:56:06 [2785] PASS level3 10.249.10.91 level3 ads http://dm.ccmbg.com/28.... GET",
"@version": "1",
"@timestamp": "2015-10-07T13:42:20.958Z",
"type": "ufdb",
"logdate": "2015-11-30T14:56:06.000Z",
"status": "PASS",
"group": "level3",
"ip": "10.249.10.91",
"category": "ads",
"url": "http://dm.ccmbg.com/28....",
"method": "GET"
}
},
On my output I want to remove the message field like I have done for "file,host,offset"
When I do a remove or remove_field, I just don’t get any data in my index.
Is it possible to remove the message ?
Here is the output I want :
"hits": {
"total": 8165,
"max_score": 1,
"hits": [
{
"_index": "shit",
"_type": "ufdb",
"_id": "AVBCidxwvfdc1_d4SQML",
"_score": 1,
"_source": {
"@version": "1",
"@timestamp": "2015-10-07T13:42:20.958Z",
"type": "ufdb",
"logdate": "2015-11-30T14:56:06.000Z",
"status": "PASS",
"group": "level3",
"ip": "10.249.10.91",
"category": "ads",
"url": "http://dm.ccmbg.com/28....",
"method": "GET"
}
},
Any ideas ?