# Changing jdbc river mysql credentials

**URL:** https://discuss.elastic.co/t/changing-jdbc-river-mysql-credentials/24678
**Category:** Elasticsearch
**Created:** [July 1, 2015, 5:28am UTC](https://discuss.elastic.co/t/changing-jdbc-river-mysql-credentials/24678 "2015-07-01T05:28:55Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![sohilelasticsearch](https://avatars.discourse-cdn.com/v4/letter/s/ecc23a/32.png) [@sohilelasticsearch](https://discuss.elastic.co/u/sohilelasticsearch)
#### Post date: [July 1, 2015, 5:28am UTC](https://discuss.elastic.co/t/changing-jdbc-river-mysql-credentials/24678/1 "2015-07-01T05:28:55Z")

</div>

Hi All,

I am using Elastic Search 1.4.2 on Production server and I am extracting data from mysql to ES using jdbc river.

```auto
curl -XPUT '10.XXX.XXX.XX:9200/_river/url_jdbc_river/_meta' -d '{
"type" : "jdbc",
"jdbc" : {
"strategy": "simple",
"autocommit": true,
"driver" : "com.mysql.jdbc.Driver",
"url" : "jdbc:mysql://10.XXX.XXX.XX:3306/DomainDB",
"user" : "sohil",
"password" : "XXX",
"sql" : [ 
{
"statement" : "select id as \"id\", pid as \"pid\" ,s_id as \"sid\" ,domain_name as \"domain\" from domaintable"
}
],
"maxbulkactions":5000,
"maxconcurrrentbulkactions":1,
"index" : "urls",
"type" : "url",
"type_mapping": {"urls" : {"properties" : {"id":{"type":"long","store":"yes"},"domain":{"type":"string","store":"yes","index":"notanalyzed"},"pid":{"type":"long","store":"yes"},"sid":{"type":"long","store":"yes"}}}}
}

}'

```

Now I want to update mysql credentials of jdbc river.  
Is there a ways using which I can update mysql credentials without affecting data of Elastic Search?.

---

<div class="post-metadata">

### Author: ![sohilelasticsearch](https://avatars.discourse-cdn.com/v4/letter/s/ecc23a/32.png) [@sohilelasticsearch](https://discuss.elastic.co/u/sohilelasticsearch)
#### Post date: [July 3, 2015, 6:13am UTC](https://discuss.elastic.co/t/changing-jdbc-river-mysql-credentials/24678/2 "2015-07-03T06:13:22Z")

</div>

Can anyone please assist me here?

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [July 3, 2015, 6:28am UTC](https://discuss.elastic.co/t/changing-jdbc-river-mysql-credentials/24678/3 "2015-07-03T06:28:24Z")

</div>

try to remove the river and create it again with new credentials.  
I guess this could work.

Note that `_river` endpoint has been removed in elasticsearch 2.0.0.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [July 6, 2017, 12:03am UTC](https://discuss.elastic.co/t/changing-jdbc-river-mysql-credentials/24678/4 "2017-07-06T00:03:49Z")

</div>


