Output logs with date of indexing Logstash

 Hey everbody,

I'am moving olds Elasticsearch logs (2.2.0) to a higer version (5.0.2) with Logstash. It's working but I can't index the logs in the new version with the date of indexing of the old logs.

I'm using the following conf structure :

input
{
elasticsearch
{
hosts => ["localhost:9200"]
index => "old-logs*"
}
}

output
{
elasticsearch
{
hosts => ["localhost:9201"]
index => "old-logs..." # looking for index with the date of indexing #
}
stdout { codec => rubydebug }
}

I don't know how to index the logs with there date...

Can anybody help me?

J.S

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.