I set the prospectors to ingest Nginx log to ES by fileBeat 5.5.0, and I found the type is "_type": "doc". I want to change the type name doc to other name, how to do it ?
**My config :**
filebeat.prospectors:
- type: log
enabled: true
paths:
#- /var/log/*.log
#
- D:\nginx-1.13.8\logs\access.log
#- c:\programdata\elasticsearch\logs\*
**The indexed document in the ES.**
{
"_index": "filebeat-2018.03.20",
"_type": **"doc",**
"_id": "P7-2Q2IBoQbqqlRr8Tx9",
"_version": 1,
"_score": 1,
"_source": {
"@timestamp": "2018-03-20T14:01:20.288Z",
"beat": {
"hostname": "HQ-PAB41656",
"name": "HQ-PAB41656",
"version": "5.5.0"
},
"input_type": "log",
"message": "2018/03/20 22:01:11 [error] 7628#11008: *71 CreateFile() \"D:\\nginx-1.13.8/html/gggg\" failed (2: The system cannot find the file specified), client: 127.0.0.1, server: localhost, request: \"GET /gggg HTTP/1.1\", host: \"localhost:808\"",
"offset": 35280,
"source": "D:\\nginx-1.13.8\\logs\\error.log",
"type": "log"
},
"fields": {
"@timestamp": [
"2018-03-20T14:01:20.288Z"
]
}
}