Created
October 5, 2012 16:14
-
-
Save jordansissel/3840775 to your computer and use it in GitHub Desktop.
logstash index template for elasticsearch
This file contains hidden or 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
curl -XPUT http://localhost:9200/_template/logstash-template -d ' | |
{ | |
"template": "logstash-*", | |
"settings": { | |
"index.cache.field.type": "soft", | |
"index.compress.stored": true, | |
"index.merge.policy.max_merged_segment": "5g", | |
"index.query.default_field": "@message", | |
"index.refresh_interval": "5s", | |
"index.store.compress.stored": true, | |
"index.term_index_divisor": 1, | |
"index.term_index_interval": 128, | |
"number_of_replicas": 1, | |
"number_of_shards": 5 | |
}, | |
"mappings": { | |
"_default_": { | |
"@fields": { "type": "object", "dynamic": true, "path": "full" }, | |
"@message": { "type": "string", "index": "analyzed" }, | |
"@source": { "type": "string", "index": "not_analyzed" }, | |
"@source_host": { "type": "string", "index": "not_analyzed" }, | |
"@source_path": { "type": "string", "index": "not_analyzed" }, | |
"@tags": { "type": "string", "index": "not_analyzed" }, | |
"@timestamp": { "type": "date", "index": "not_analyzed" }, | |
"@type": { "type": "string", "index": "not_analyzed" } | |
} | |
} | |
}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment