# Deleting index using DELETE in dev tools leads to error

**URL:** https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965
**Category:** Kibana
**Created:** [April 23, 2019, 7:33am UTC](https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965 "2019-04-23T07:33:19Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![sahere37](https://avatars.discourse-cdn.com/v4/letter/s/b2d939/32.png) [@sahere37](https://discuss.elastic.co/u/sahere37)
#### Post date: [April 23, 2019, 7:33am UTC](https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965/1 "2019-04-23T07:33:19Z")

</div>

hi all,

I found following error in elasticsearch log:

```
  [2019-04-23T11:28:20,537][DEBUG][o.e.a.s.TransportSearchAction] [node-S11] [dis_–êw][1], node[2AqXLcbmSmqyWhrWxqkdFA], [R], s[STARTED], a[id=g3i5xwTSRwuOmF5PTx9qTQ]: Failed to execute [SearchRequest{searchType=QUERY_THEN_FETCH, indices=[dis_*], indicesOptions=IndicesOptions[ignore_unavailable=true, allow_no_indices=true, expand_wildcards_open=true, expand_wildcards_closed=false, allow_aliases_to_multiple_indices=true, forbid_closed_indices=true, ignore_aliases=false], types=[], routing='null', preference='1555979423655', requestCache=null, scroll=null, maxConcurrentShardRequests=15, batchedReduceSize=512, preFilterShardSize=14, allowPartialSearchResults=true, source={"size":0,"timeout":"30000ms","query":{"bool":{"must":[{"match_all":{"boost":1.0}},{"match_all":{"boost":1.0}},{"range":{"Date_Time":{"from":1556002100547,"to":1556002700547,"include_lower":true,"include_upper":true,"format":"epoch_millis","boost":1.0}}}],"adjust_pure_negative":true,"boost":1.0}},"_source":{"includes":[],"excludes":[]},"stored_fields":"*","docvalue_fields":[{"field":"@timestamp","format":"date_time"},{"field":"Date","format":"date_time"},{"field":"Date_Time","format":"date_time"},{"field":"PDate","format":"date_time"},{"field":"PDate_Time","format":"date_time"}],"script_fields":{},"aggregations":{"2":{"date_histogram":{"field":"Date_Time","interval":"10s","offset":0,"order":{"_key":"asc"},"keyed":false,"min_doc_count":1},"aggregations":{"3":{"terms":{"field":"host.name.keyword","size":5,"min_doc_count":1,"shard_min_doc_count":0,"show_term_doc_count_error":false,"order":[{"1":"desc"},{"_key":"asc"}]},"aggregations":{"1":{"max":{"field":"PacketDuration"}}}}}}}}}] lastShard [true]
  org.elasticsearch.transport.RemoteTransportException: [node-12][0.0.0.12:9300][indices:data/read/search[phase/query]]
Caused by: java.lang.IllegalArgumentException: Fielddata is disabled on text fields by default. Set fielddata=true on [Date_Time] in order to load fielddata in memory by uninverting the inverted index. Note that this can however use significant memory. Alternatively use a keyword field instead.
at org.elasticsearch.index.mapper.TextFieldMapper$TextFieldType.fielddataBuilder(TextFieldMapper.java:670) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.index.fielddata.IndexFieldDataService.getForField(IndexFieldDataService.java:115) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.index.query.QueryShardContext.getForField(QueryShardContext.java:166) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.support.ValuesSourceConfig.resolve(ValuesSourceConfig.java:95) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder.resolveConfig(ValuesSourceAggregationBuilder.java:317) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder.doBuild(ValuesSourceAggregationBuilder.java:310) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder.doBuild(ValuesSourceAggregationBuilder.java:37) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.AbstractAggregationBuilder.build(AbstractAggregationBuilder.java:139) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.AggregatorFactories$Builder.build(AggregatorFactories.java:336) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService.parseSource(SearchService.java:807) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService.createContext(SearchService.java:616) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService.createAndPutContext(SearchService.java:592) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:367) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService.access$100(SearchService.java:121) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService$2.onResponse(SearchService.java:339) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService$2.onResponse(SearchService.java:335) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.SearchService$4.doRun(SearchService.java:1082) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:723) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.common.util.concurrent.TimedRunnable.doRun(TimedRunnable.java:41) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) ~[elasticsearch-6.5.4.jar:6.5.4]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) ~[?:1.8.0_152]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[?:1.8.0_152]
at java.lang.Thread.run(Unknown Source) [?:1.8.0_152]

```

actually, the index had been named based on the following template:

```
"dis_%{Date}

```

but the value of "Date" is wrong in some input records which leads to wrong index, now I want to delete this index using following command in dev tools of kibana:

DELETE /dis\_–êw, but following error has been found, how can i delete this index?

```
{
  "statusCode": 500,
  "error": "Internal Server Error",
  "message": "An internal server error occurred"
}
```

---

<div class="post-metadata">

### Author: ![Bargs](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/bargs/32/5429_2.png) [@Bargs](https://discuss.elastic.co/u/Bargs)
#### Post date: [April 23, 2019, 11:12pm UTC](https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965/2 "2019-04-23T23:12:34Z")

</div>

Do you see an error in your Elasticsearch log when executing the request in dev tools? (the first error you posted doesn't look like one I'd expect to get from that request). You might also be able to see the error in the network tab of your browser's dev tools.

---

<div class="post-metadata">

### Author: ![sahere37](https://avatars.discourse-cdn.com/v4/letter/s/b2d939/32.png) [@sahere37](https://discuss.elastic.co/u/sahere37)
#### Post date: [April 27, 2019, 3:21am UTC](https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965/3 "2019-04-27T03:21:57Z")

</div>

@Bargs many thanks for your reply, elasticsearch log had been checked and there is nothing except the mentioned message:

```
  [2019-04-23T11:28:20,537][DEBUG][o.e.a.s.TransportSearchAction] [node-S11] [dispatcher-card1_packets_–êw][1], node[2AqXLcbmSmqyWhrWxqkdFA], [R], s[STARTED], a[id=g3i5xwTSRwuOmF5PTx9qTQ]: Failed to execute [SearchRequest{searchType=QUERY_THEN_FETCH, indices=[dis*], indicesOptions=IndicesOptions[ignore_unavailable=true, allow_no_indices=true, expand_wildcards_open=true, expand_wildcards_closed=false, allow_aliases_to_multiple_indices=true, forbid_closed_indices=true, ignore_aliases=false], types=[], routing='null', preference='1555979423655', requestCache=null, scroll=null, maxConcurrentShardRequests=15, batchedReduceSize=512, preFilterShardSize=14, allowPartialSearchResults=true, source={"size":0,"timeout":"30000ms","query":{"bool":{"must":[{"match_all":{"boost":1.0}},{"match_all":{"boost":1.0}},{"range":{"Date_Time":{"from":1556002100547,"to":1556002700547,"include_lower":true,"include_upper":true,"format":"epoch_millis","boost":1.0}}}],"adjust_pure_negative":true,"boost":1.0}},"_source":{"includes":[],"excludes":[]},"stored_fields":"*","docvalue_fields":[{"field":"@timestamp","format":"date_time"},{"field":"Date","format":"date_time"},{"field":"Date_Time","format":"date_time"},{"field":"PDate","format":"date_time"},{"field":"PDate_Time","format":"date_time"}],"script_fields":{},"aggregations":{"2":{"date_histogram":{"field":"Date_Time","interval":"10s","offset":0,"order":{"_key":"asc"},"keyed":false,"min_doc_count":1},"aggregations":{"3":{"terms":{"field":"host.name.keyword","size":5,"min_doc_count":1,"shard_min_doc_count":0,"show_term_doc_count_error":false,"order":[{"1":"desc"},{"_key":"asc"}]},"aggregations":{"1":{"max":{"field":"PacketDuration"}}}}}}}}}] lastShard [true]
 org.elasticsearch.transport.RemoteTransportException: [node-12][0.0.0.12:9300][indices:data/read/search[phase/query]]
Caused by: java.lang.IllegalArgumentException: Fielddata is disabled on text fields by default. Set fielddata=true on [Date_Time] in order to load fielddata in memory by uninverting the inverted index. Note that this can however use significant memory. Alternatively use a keyword field instead.
at org.elasticsearch.index.mapper.TextFieldMapper$TextFieldType.fielddataBuilder(TextFieldMapper.java:670) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.index.fielddata.IndexFieldDataService.getForField(IndexFieldDataService.java:115) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.index.query.QueryShardContext.getForField(QueryShardContext.java:166) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.support.ValuesSourceConfig.resolve(ValuesSourceConfig.java:95) ~[elasticsearch-6.5.4.jar:6.5.4]
at org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder.resolveConfig(ValuesSourceAggregationBuilder.java:317) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder.doBuild(ValuesSourceAggregationBuilder.java:310) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder.doBuild(ValuesSourceAggregationBuilder.java:37) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.aggregations.AbstractAggregationBuilder.build(AbstractAggregationBuilder.java:139) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.aggregations.AggregatorFactories$Builder.build(AggregatorFactories.java:336) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService.parseSource(SearchService.java:807) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService.createContext(SearchService.java:616) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService.createAndPutContext(SearchService.java:592) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:367) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService.access$100(SearchService.java:121) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService$2.onResponse(SearchService.java:339) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService$2.onResponse(SearchService.java:335) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.search.SearchService$4.doRun(SearchService.java:1082) ~[elasticsearch-6.5.4.jar:6.5.4]

  at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:723) ~[elasticsearch-6.5.4.jar:6.5.4]

 at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) ~[elasticsearch-6.5.4.jar:6.5.4]

   at org.elasticsearch.common.util.concurrent.TimedRunnable.doRun(TimedRunnable.java:41) ~[elasticsearch-6.5.4.jar:6.5.4]

at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) ~[elasticsearch-6.5.4.jar:6.5.4]

 at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) ~[?:1.8.0_152]

 at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[?:1.8.0_152]
at java.lang.Thread.run(Unknown Source) [?:1.8.0_152]

```

following has been found in network tab of chrome's dev tools:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/2/6/26eb7428419175cd9f99bfc9d258fdda8547c3bb.png)

notably, in this case the index name is "dispatcher-card1\_packets\_–êw"

executing the command "GET \_cat/indices?v" leads to following:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/4/c/4c1f2db0a54091ae30ccf3844c0f0c5047ed4748.png)

in addition, when i execute following command "DELETE /dispatcher-card1\_packets\_–êw" and "GET /dispatcher-card1\_packets\_–êw/\_count" in dev's tools of kibana the same error can be found:

![image](https://us1.discourse-cdn.com/elastic/original/3X/6/5/65cb1de9875b51bf7b685aef096fedbf302b48e6.png)

---

<div class="post-metadata">

### Author: ![sahere37](https://avatars.discourse-cdn.com/v4/letter/s/b2d939/32.png) [@sahere37](https://discuss.elastic.co/u/sahere37)
#### Post date: [April 29, 2019, 9:31am UTC](https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965/4 "2019-04-29T09:31:21Z")

</div>

@Bargs could you please advise me about this case?

---

<div class="post-metadata">

### Author: ![Bargs](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/bargs/32/5429_2.png) [@Bargs](https://discuss.elastic.co/u/Bargs)
#### Post date: [April 29, 2019, 4:33pm UTC](https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965/5 "2019-04-29T16:33:54Z")

</div>

If there are no additional error messages in the ES log then that makes me think the issue must be in Kibana or between Kibana and ES. Do you see any errors in the Kibana log? You may need to enable the `logging.verbose` setting in kibana.yml.

---

<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: [May 27, 2019, 4:33pm UTC](https://discuss.elastic.co/t/deleting-index-using-delete-in-dev-tools-leads-to-error/177965/6 "2019-05-27T16:33:54Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
