Skip to content

Instantly share code, notes, and snippets.

@coregear
Forked from markwalkom/logstash.conf
Created November 12, 2015 10:00
Show Gist options
  • Select an option

  • Save coregear/793fc4c4783ee4b05184 to your computer and use it in GitHub Desktop.

Select an option

Save coregear/793fc4c4783ee4b05184 to your computer and use it in GitHub Desktop.
Reindexing Elasticsearch with Logstash 1.5
input {
elasticsearch {
hosts => [ "HOSTNAME_HERE" ]
port => "9200"
index => "INDEXNAME_HERE"
size => 1000
scroll => "5m"
docinfo => true
scan => true
}
}
output {
elasticsearch {
host => "localhost"
protocol => "http"
index => "%{[@metadata][_index]}"
index_type => "%{[@metadata][_type]}"
document_id => "%{[@metadata][_id]}"
}
stdout {
codec => "dots"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment