output: how to select index?
Posted: Fri Jan 06, 2017 6:15 am
Hi,
Background:
Our logstash index is currently up to 10GB per day. We are using a single instance. We have different retention intervals per logfile - that means log 1 a we need to keep a month, log 2 we sould keep for the last 3 month as example. Logs from dev systems may be deleted after 2 weeks, etc.
Target:
I would like to split up the indexes and use different index patterns. Logstash should route by type for example.
Following aims want want to reach:
- be able to choose which logfiles I can delete to save space and memory, because as I understand the bigger an opened index is, it consumes memory in ES.
- faster searches because of smaller indizes to search, if I search within a specific log file.
Questions:
- are all mentioned targets above solvable by using multiple indexes, or do I reach the opposite, especially on ES's memory usage and search times?
- How can I define an output which routes the type "log-application-1" only to index "indx_app1-{ddmmyyyy}" ?
- I know that I can only set one index name for a dashboard. I read about using aliases to make kibana / ES able to search in different indexes. So is it possible to link indx_app1-* and logstash-* to the same alias "myAlias"? In the dashboard then I would set "myAlias" as index pattern.
Thanks, Andreas
Background:
Our logstash index is currently up to 10GB per day. We are using a single instance. We have different retention intervals per logfile - that means log 1 a we need to keep a month, log 2 we sould keep for the last 3 month as example. Logs from dev systems may be deleted after 2 weeks, etc.
Target:
I would like to split up the indexes and use different index patterns. Logstash should route by type for example.
Following aims want want to reach:
- be able to choose which logfiles I can delete to save space and memory, because as I understand the bigger an opened index is, it consumes memory in ES.
- faster searches because of smaller indizes to search, if I search within a specific log file.
Questions:
- are all mentioned targets above solvable by using multiple indexes, or do I reach the opposite, especially on ES's memory usage and search times?
- How can I define an output which routes the type "log-application-1" only to index "indx_app1-{ddmmyyyy}" ?
- I know that I can only set one index name for a dashboard. I read about using aliases to make kibana / ES able to search in different indexes. So is it possible to link indx_app1-* and logstash-* to the same alias "myAlias"? In the dashboard then I would set "myAlias" as index pattern.
Thanks, Andreas