Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Migrating data from solr to elastic search

What would be the best way to migrate Solr cores to elastic search indices ?

The solr-river-plugin (https://github.com/javanna/elasticsearch-river-solr) is deprecated.

like image 897
rangalo Avatar asked Nov 10 '16 12:11

rangalo


1 Answers

There's a nice adhoc Python tool made with love by the nice folks at OpenSource Connections that you can use to do this:

https://github.com/o19s/solr-to-es

Simply

./solr-to-es solr_url elasticsearch_url elasticsearch_index doc_type

For instance, the command below will page through all documents on the local Solr node, named node, and submit them to the local Elasticsearch server in the index my_index with a document type of my_type.

./solr-to-es.py localhost:8983/solr/node localhost:9200 my_index my_type
like image 145
Val Avatar answered Sep 28 '22 03:09

Val