cancel
Showing results for 
Search instead for 
Did you mean: 

Elasticsearch version for 2.4

Elasticsearch version for 2.4

Planning to upgrade to 2.4 and I was wondering will Magento work on Elasticsearch 7.8 or is it better to go to 7.0?

Anyone tested this yet?

7 REPLIES 7

Re: Elasticsearch version for 2.4

Magento 2.4 officially supports Elasticsearch 7.6.x but should work with 7.8.x as well.

 

If you are risk averse, you can go with 7.6.x but otherwise you can give 7.8.x a try since it is still part of the same branch.

Re: Elasticsearch version for 2.4

Magento 2.4 adds support for Elasticsearch 6.x, and it is enabled by default. You must install and configure Elasticsearch 7.6.x before upgrading to Magento 2.4.0.

Re: Elasticsearch version for 2.4

Tried with 7.6.2 and it did not work. There is an error in documentation. Minimum requiered version of elasticsearch is 7.7.0

- magento/product-community-edition 2.4.0 requires elasticsearch/elasticsearch ~7.7.0 -> satisfiable by elasticsearch/elasticsearch[7.7.x-dev, v7.7.0] but these conflict with your requirements or minimum-stability.
- magento/product-community-edition 2.4.0 requires elasticsearch/elasticsearch ~7.7.0 -> satisfiable by elasticsearch/elasticsearch[7.7.x-dev, v7.7.0] but these conflict with your requirements or minimum-stability.
- Installation request for magento/product-community-edition 2.4.0 -> satisfiable by magento/product-community-edition[2.4.0].

Re: Elasticsearch version for 2.4

@ivan_golubovic 

 

Sorry for the slow reply!

I have a large customer store that is running Magento 2.4.x and Elasticsearch 7.9.0 with zero issues and no customisations.

Just wanted to confirm it works Smiley Happy

--
Problem solved? Click Accept as Solution!

Re: Elasticsearch version for 2.4

Hi everybody,

 

I'm testing to migrate from Magento 2.2.7 to Magento 2.4.1.

My Develop configuration into Oracle VM (then will be replicated on VPS) is  :

FreeBSD 12.1 (base host + pf Firewall redirect traffic) --> jail proxy (haproxy2.2.4 + ssl) --> jail www (nginx 1.18.0_25 + ssl + php7.4.12 + elasticsearch7.9.1 + modsecurity3-3.0.4_2 + Magento 2.4.1) --> jail db (Mysql Server 8.0.22)

 

This configuration works fine and I was very happy, but when I run "php bin/magento index:reindex" I received from shell the follow error on "Catalog Search index" :

 

.....Catalog Product Rule index has been rebuilt successfully in 00:00:00
Product Price index has been rebuilt successfully in 00:00:00
Catalog Search index  
Fatal error: Uncaught Error: Wrong parameters for Elasticsearch\Common\Exceptions\ServerErrorResponseException([string $message [, long $code [, Throwable $previous
= NULL]]]) in ..../vendor/elasticsearch/elasticsearch/src/Elasticsearch/Connections/Connection.php:665
Stack trace:
#0 ..../vendor/elasticsearch/elasticsearch/src/Elasticsearch/Connections/Connection.php(665): Exception->__construct(NULL, 503)
#1 ..../vendor/elasticsearch/elasticsearch/src/Elasticsearch/Connections/Connection.php(320): Elasticsearch\Connections\Connection->process5xxEr
ror(Array, Array, Array)
#2 .../vendor/react/promise/src/FulfilledPromise.php(28): Elasticsearch\Connections\Connection->Elasticsearch\Connections\{closure}(Array)
#3 ..../vendor/ezimuel/ringphp/src/Future/CompletedFutureValue.php(55): React\Promise\FulfilledPromise->then(Object(Closure), NULL, NULL)
#4 ..../vendor/ezimuel/ringphp/src/Core.php(341): Guzzl in ..../vendor/elasticsearch/elasticsearch/src/Elasticsearch/Connec
tions/Connection.php on line 665


On FreeBSD I cannot downgrade elasticsearch to version 7.6 (as in requirements) and I just tried to susbstitute the directories "lib", "module" and "plugin" on /usr/local/lib/elasticsearch with previuos version but without success.

Any suggestion is appreciated to resolve the problem.
Thank in advance, Matteo

Re: Elasticsearch version for 2.4

You can solve this issue by downgrading from ElasticSearch 7.8.x (latest) to 7.6.2 explicitly.

See this github topic, there's a person who encounter the same issue: https://github.com/magento/magento2/issues/29454

Re: Elasticsearch version for 2.4

If you are using M2.4, its better to go for Elasticsearch version 7.6 and above, since it does not support the lower versions. Guiding the steps through which one can update the version, it may help you or someone who needs it.

Step 1: Configuration of the search option in your store

  1. Access the configuration settings by selecting "Stores" from the sidebar and then choosing the "Configuration" option.
  2. Under the "Catalog" section, click on "Catalog" to expand the menu.
  3. Click on "Catalog Search" to access the search configuration settings.
  4. Uncheck the "Use system value" checkbox and select the appropriate Elasticsearch version installed on your server.

Step 2: Configuration of Elasticsearch Connection

  1. Fill in the details for the Elasticsearch server configuration.
    • Enter the Elasticsearch server hostname (default is localhost).
    • Insert the Elasticsearch server port.
    • Provide a prefix for the Elasticsearch index.
    • Choose whether to enable HTTP authentication for Elasticsearch server access and enter the recommended username and password.
    • Set the timeout value for the Elasticsearch server connection.
    • Test the connection to verify its success.

Step 3: Configuration of Suggestions and Recommendations

  1. Enable search suggestions by selecting "Yes" in the "Enable Search Suggestions" option.
  2. Specify the number of search suggestions you want to offer in the "Search Suggestions Count" field.
  3. Choose whether to show results for each suggestion and enable search recommendations.
  4. Set the number of search recommendations to offer in the "Search Recommendation Count" field.
  5. Decide whether to display the number of results obtained for each recommendation.
  6. Save the configuration by clicking on the "Save Config" option.