# Visualize: Bad Gateway & Courier Fetch (shards failed)

**URL:** <https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496>\
**Category:** Kibana\
**Created:** [June 7, 2017, 3:15am UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496 "2017-06-07T03:15:16Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![alexus](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alexus/32/12696_2.png) [@alexus](https://discuss.elastic.co/u/alexus)\
**Post date:** [June 7, 2017, 3:15am UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496/1 "2017-06-07T03:15:16Z")

</div>

I'm using Kibana's (5.4.0) and while trying to access _Dashboard_ for 30 days, I'm getting following (red) error:

```
Error: Bad Gateway
    at respond (https://foo.bar/bundles/kibana.bundle.js?v=15063:13:2730)
    at checkRespForFailure (https://foo.bar/bundles/kibana.bundle.js?v=15063:13:1959)
    at https://foo.bar/bundles/kibana.bundle.js?v=15063:1:28418
    at processQueue (https://foo.bar/bundles/commons.bundle.js?v=15063:38:23621)
    at https://foo.bar/bundles/commons.bundle.js?v=15063:38:23888
    at Scope.$eval (https://foo.bar/bundles/commons.bundle.js?v=15063:39:4619)
    at Scope.$digest (https://foo.bar/bundles/commons.bundle.js?v=15063:39:2359)
    at Scope.$apply (https://foo.bar/bundles/commons.bundle.js?v=15063:39:5037)
    at done (https://foo.bar/bundles/commons.bundle.js?v=15063:37:25027)
    at completeRequest (https://foo.bar/bundles/commons.bundle.js?v=15063:37:28702)

```

\__cat/thead\_pool_: (while accessing)

```
foo bulk 1 0 0
foo fetch_shard_started 0 0 0
foo fetch_shard_store 0 0 0
foo flush 0 0 0
foo force_merge 0 0 0
foo generic 0 0 0
foo get 0 0 0
foo index 0 0 0
foo listener 0 0 0
foo management 1 0 0
foo refresh 2 0 0
foo search 0 0 0
foo snapshot 0 0 0
foo warmer 0 0 0

```

yet with 7 days, I'm getting (yellow) error:

> Courier Fetch: 55 of 145 shards failed.

[/var/log/elasticsearch/elasticsearch.log](https://pastebin.com/xhQPFWXK) @pastebin.com

Please advise.  
Thanks in advance!

---

<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:** [June 7, 2017, 9:56am UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496/2 "2017-06-07T09:56:13Z")

</div>

What does ES show in the logs at this time?

---

<div class="post-metadata">

**Author:** ![alexus](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alexus/32/12696_2.png) [@alexus](https://discuss.elastic.co/u/alexus)\
**Post date:** [June 9, 2017, 2:45am UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496/4 "2017-06-09T02:45:01Z")

</div>

I updated my topic with output from elasticsearch.log.

---

<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:** [June 10, 2017, 12:13am UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496/5 "2017-06-10T00:13:59Z")

</div>

```auto
Caused by: java.lang.IllegalArgumentException: Fielddata is disabled on text fields by default. Set fielddata=true on [shopId] 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.

```

You need to update your mappings as the error suggests 🙂

---

<div class="post-metadata">

**Author:** ![alexus](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alexus/32/12696_2.png) [@alexus](https://discuss.elastic.co/u/alexus)\
**Post date:** [June 10, 2017, 2:59am UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496/6 "2017-06-10T02:59:11Z")

</div>

> [@warkolm](#):
>
> You need to update your mappings as the error suggests 🙂

per my mapping _shopId_ already set as _keyword_ type:

> ```
> "shopId": {
> "type": "keyword"
> },
> 
> ```

---

<div class="post-metadata">

**Author:** ![alexus](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alexus/32/12696_2.png) [@alexus](https://discuss.elastic.co/u/alexus)\
**Post date:** [June 19, 2017, 8:09pm UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496/7 "2017-06-19T20:09:21Z")

</div>

after I \__reindex_ all of my indices, previous error that was appearing in logs before went away, however

> Visualize: Request Timeout after 30000ms

still showing up on top of screen, and I'm not seeing anything in logs when I get an error...

---

<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 17, 2017, 8:09pm UTC](https://discuss.elastic.co/t/visualize-bad-gateway-courier-fetch-shards-failed/88496/8 "2017-07-17T20:09:29Z")

</div>

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