# Indexing with elasticsearch gives warning / 404

**URL:** <https://forum.shopware.com/t/indexing-with-elasticsearch-gives-warning-404/85697>\
**Category:** Installation / Getting Started (EN)\
**Tags:** installation--gettin\
**Created:** [4. März 2021 um 15:24 UTC](https://forum.shopware.com/t/indexing-with-elasticsearch-gives-warning-404/85697 "2021-03-04T15:24:23Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![adrian.hishow](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@adrian.hishow](https://forum.shopware.com/u/adrian.hishow)\
**Post date:** [4. März 2021 um 15:24 UTC](https://forum.shopware.com/t/indexing-with-elasticsearch-gives-warning-404/85697/1 "2021-03-04T15:24:23Z")

</div>

Hey community

I am playing around with the elasticsearch integration into shopware and having some problems: I followed this guide [https://docs.dockware.io/faq/elasticsearch](https://docs.dockware.io/faq/elasticsearch) to set up two docker containers (one for es one for the demo store).  
When I try to index the dummy data provided in the demo store using this guide [https://docs.shopware.com/en/shopware-platform-dev-en/how-to/using-elasticsearch](https://docs.shopware.com/en/shopware-platform-dev-en/how-to/using-elasticsearch) I run:

- php bin/console dal:refresh:index

as stated in the guide. Unfortunately I am getting only 404 responses in return:  
`15:14:18 WARNING [app] Request Failure: ["method" => "HEAD","uri" => "http://elasticsearch/abc_product_2fbb5fe2e29a4d70aa5854ce7ce3e20b","headers" => ["Host" => ["elasticsearch"],"Content-Type" => ["application/json"],"Accept" => ["application/json"],"User-Agent" => ["elasticsearch-php/7.2.2 (Linux 4.19.121-linuxkit; PHP 7.4.15)"]],"HTTP code" => 404,"duration" => 0.002015,"error" => "null"] 15:14:18 WARNING [app] Response [null]`

I’ve declared the env variables as required and they are being recognized (which can be seen by the prefix ‚abc‘ in the uri). Not sure what else I need to configure. Anyone have a suggestion?

best  
Adrian

---

<div class="post-metadata">

**Author:** ![shyim](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/shyim/32/7681_2.png) [@shyim](https://forum.shopware.com/u/shyim)\
**Post date:** [4. März 2021 um 16:46 UTC](https://forum.shopware.com/t/indexing-with-elasticsearch-gives-warning-404/85697/2 "2021-03-04T16:46:45Z")

</div>

You can ignore the error. This happens cause the index is not existing

---

<div class="post-metadata">

**Author:** ![adrian.hishow](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@adrian.hishow](https://forum.shopware.com/u/adrian.hishow)\
**Post date:** [5. März 2021 um 09:16 UTC](https://forum.shopware.com/t/indexing-with-elasticsearch-gives-warning-404/85697/3 "2021-03-05T09:16:31Z")

</div>

Hey man, first of all: thanks for answering to my thread! I appreciate it. Will look into why the index doesn’t exist yet next.

Regards,  
Adrian

---

<div class="post-metadata">

**Author:** ![shyim](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/shyim/32/7681_2.png) [@shyim](https://forum.shopware.com/u/shyim)\
**Post date:** [5. März 2021 um 09:33 UTC](https://forum.shopware.com/t/indexing-with-elasticsearch-gives-warning-404/85697/4 "2021-03-05T09:33:57Z")

</div>

You can check it with curl es-host:9200/\_indices

---

<div class="post-metadata">

**Author:** ![adrian.hishow](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@adrian.hishow](https://forum.shopware.com/u/adrian.hishow)\
**Post date:** [5. März 2021 um 12:09 UTC](https://forum.shopware.com/t/indexing-with-elasticsearch-gives-warning-404/85697/5 "2021-03-05T12:09:12Z")

</div>

Ok so apparently you need to run all of the three commands including

`php bin/console es:create:alias`

before the index is created. Not sure why this is the case but it after I can access the es index via the API
