Introduction

I haven't used Magento a whole lot in my career and this was my first time setting up a Magento website from scratch. After getting all the dependencies setup, including Elasticsearch, I tried to install the application. This is where I was encountering this error:

bash

undefined

So for the next couple hours I searched for answers. But nothing I tried worked until I came across this answer on Stack Exchange. After following the steps laid out in this answer the installation finally completed without any errors. Here are the steps:

Install the official Magento 2 Elasticsearch 8 Module

bash

undefined

Run the install command and disable modules

bash

undefined

Re-enable the modules, except Magento_OpenSearch

bash

undefined

Change default search engine to Elasticsearch 8

bash

undefined

Start Magento setup

The ElasticSearch 8 service should be running while starting the setup again.

bash

undefined

Rerun full install command

After all that, I reran the install command from the Magento docs and it ran without any issues!

bash

undefined

Final Thoughts

I was pretty close to curling up in a ball and crying before finding Tu Van's answer. So thank you to him!

Was this post helpful?