How to create ES index with a mapping and data from Mysql?


I'm using ES for creating an index with a mapping and data from Mysql. I'm
able to create an empty idex along with mappings and settings but I'm not
able to import data from Mysql into that index. I'm using this plugin with ES
1.1.0 There is no problem in version. The example shows something like this:

curl -XPUT 'localhost:9200/_river/my_jdbc_river/_meta' -d '{
"type" : "jdbc",
"jdbc" : {
"url" : "jdbc:mysql://localhost:3306/test",
"user" : "",
"password" : "",
"sql" : "select * from orders"

But how can I change it for some index INDEX and type TYPE.

curl -XPUT "localhost:9200/_river/INDEX/_meta" -d '
"type": "jdbc",
"jdbc": {
"url": "jdbc:mysql://localhost:3306/my_db",
"driver": "com.mysql.jdbc.Driver",
"user" : "root",
"password": "root",
"sql" : "select * from my_table"
"index": {
"index" : "INDEX",
"type" : "TYPE"

But this is not working for me ?

Please help me.


You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To view this discussion on the web visit
For more options, visit