# Do we have any Plugin to update Mappings on the fly?

**URL:** https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983
**Category:** Elasticsearch
**Created:** [December 11, 2015, 1:26pm UTC](https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983 "2015-12-11T13:26:49Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![vikas\_gopal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vikas_gopal/32/47661_2.png) [@vikas\_gopal](https://discuss.elastic.co/u/vikas_gopal)
#### Post date: [December 11, 2015, 1:26pm UTC](https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983/1 "2015-12-11T13:26:49Z")

</div>

Hi Experts,

I know that we can update /create or modify my existing Mappings using SENSE or I can directly achieve this with Mapping API.  
My question is do we have any GUI or plugin from where I can update/Delete/Create Mapping for an Index in elasticsearch , Plus I can also change the field type like from string to int etc on the fly. I saw ElasticHQ but in this I can only delete the mapping . Please guide or suggest any other GUI.

Thanks  
VG

---

<div class="post-metadata">

### Author: ![cbuescher](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cbuescher/32/60402_2.png) [@cbuescher](https://discuss.elastic.co/u/cbuescher)
#### Post date: [December 11, 2015, 6:49pm UTC](https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983/2 "2015-12-11T18:49:34Z")

</div>

Hi Vikas,

with a few exceptions [stated here](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-put-mapping.html), the mapping for existing fields cannot be updated. Also, starting [with 2.0 it is no longer possible to delete a type mapping](https://www.elastic.co/blog/great-mapping-refactoring#delete-mappings). To change a mapping you have to create a new index with the new mapping and reindex your data to it. For older versions, this [blog post](https://www.elastic.co/blog/changing-mapping-with-zero-downtime) describes the process. Also note there is work in progress to simplify this reindexing procedure using a dedicated API for this, see this [Github issue](https://github.com/elastic/elasticsearch/issues/15201) for details.

---

<div class="post-metadata">

### Author: ![vikas\_gopal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vikas_gopal/32/47661_2.png) [@vikas\_gopal](https://discuss.elastic.co/u/vikas_gopal)
#### Post date: [December 11, 2015, 7:01pm UTC](https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983/3 "2015-12-11T19:01:34Z")

</div>

Thanks for the response Chris,

I like Alias Idea , but since i am new so I followed the instruction as per blog the only challenge for me is to copy old index document into new index .Till now what I have done is

1. I have created alias for my existing Index and then create a new index with new name and mapping and assigned the same alias name to it.e.g

> ```
> POST /_aliases> {
> "actions": [
> { "remove": {
> "alias": "vikas_alias",
> "index": "corr"
> }},
> { "add": {
> "alias": "vikas_alias",
> "index": "vikas"
> }}
> ]
> 
> ```

Here **corr** is my old index and **vikas** is my new index.

1. After doing all above I can see following after firing **GET /\_cat/indices/?v**

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [December 11, 2015, 11:55pm UTC](https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983/4 "2015-12-11T23:55:18Z")

</div>

You can use something like Logstash to do that, [https://gist.github.com/markwalkom/8a7201e3f6ea4354ae06](https://gist.github.com/markwalkom/8a7201e3f6ea4354ae06)

---

<div class="post-metadata">

### Author: ![vikas\_gopal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vikas_gopal/32/47661_2.png) [@vikas\_gopal](https://discuss.elastic.co/u/vikas_gopal)
#### Post date: [December 12, 2015, 1:51pm UTC](https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983/5 "2015-12-12T13:51:09Z")

</div>

Thanks Mark,

It works.

---

<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 5, 2017, 11:31pm UTC](https://discuss.elastic.co/t/do-we-have-any-plugin-to-update-mappings-on-the-fly/36983/6 "2017-07-05T23:31:32Z")

</div>


