Hi Friends,
I'm starting using the ELK Stack to create a sort of Log Archiving and Log Analyses tool to my team.
I have some firewalls and need change some fields to not_analyzed.
I don't know why, but when I load Kibana, all my fields seems as Analyzed. What is the right manner to apply fields mapping templates?
Thanks in advance for the help.
Here is my conf of Logstash:
.... output { if [type] == "netscreen_traffic" { elasticsearch { hosts => ["localhost:9200"] index => "firewall-traffic-%{+YYYY.MM.DD}" manage_template => false template_overwrite => true template_name => "firewall-traffic" #template => "/etc/logstash/templates/firewall-traffic.json" } }
Here is my mapping json:
{ "template" : "firewall-traffic", "mappings": { "netscreen_traffic": { "action": { "type": "string" }, "device": { "type": "string", "index": "not_analyzed" }, "device_id": { "type": "string", "index": "not_analyzed" }, "dst_ip": { "type": "ip" }, "dst_port": { "type": "string" }, "dst_xlated_ip": { "type": "ip" }, "dst_xlated_port": { "type": "string" }, "dst_zone": { "type": "string", "index": "not_analyzed" }, "duration": { "type": "string" }, "host": { "type": "string", "index": "not_analyzed" }, "message": { "type": "string" }, "policy_id": { "type": "string" }, "priority": { "type": "string" }, "proto": { "type": "string" }, "rcvd": { "type": "integer" }, "reason": { "type": "string", "index": "not_analyzed" }, "sent": { "type": "integer" }, "service": { "type": "string" }, "session_id": { "type": "string" }, "src_ip": { "type": "ip" }, "src_port": { "type": "string" }, "src_xlated_ip": { "type": "ip" }, "src_xlated_port": { "type": "string" }, "src_zone": { "type": "string", "index": "not_analyzed" }, "start_time": { "type": "date" }, "syslog5424_pri": { "type": "string" }, "tags": { "type": "string" }, "type": { "type": "string" } } } }