2

I'm running this command:

C:\xampp\htdocs\magento2>php bin/magento indexer:reindex

But I'm getting an error (at bottom of message):

Design Config Grid index has been rebuilt successfully in 00:00:00
Customer Grid index has been rebuilt successfully in 00:00:03
Product Flat Data index has been rebuilt successfully in 00:00:02
Category Flat Data index has been rebuilt successfully in 00:00:01
Category Products index has been rebuilt successfully in 00:00:01
Product Categories index has been rebuilt successfully in 00:00:00
Catalog Rule Product index has been rebuilt successfully in 00:00:02
Product EAV index has been rebuilt successfully in 00:00:02
Stock index has been rebuilt successfully in 00:00:01
Inventory index has been rebuilt successfully in 00:00:00
Catalog Product Rule index has been rebuilt successfully in 00:00:00
Product Price index has been rebuilt successfully in 00:00:01
Catalog Search index process error during indexation process:
{"error":"no handler found for uri[/magento2_product_1_v3/document/_mappinginclude_type_name=true] and method [PUT]"}
2
  • 1
    @Mukesh, please try to make more substantive edits. This post had a lot of problems besides unnecessary leading line breaks. Jun 7, 2023 at 19:47
  • @GeneralGrievance I will keep it in mind for any edits in future.
    – Mukesh
    Jun 8, 2023 at 11:38

3 Answers 3

6

Looks like you are using Elasticsearch version 8.x which is not supported by Magento 2 at this time.

So, change Elasticsearch to version 7.x to resolve this issue.

You can read more about system requirements for Elasticsearch from the official document: https://experienceleague.adobe.com/docs/commerce-operations/installation-guide/system-requirements.html


Update

The default Magento 2.4.6 does not support Elasticsearch 8. To use Elasticsearch 8, you will need to install the magento/module-elasticsearch-8 module as outlined in the "Complete upgrade prerequisites" guide: https://experienceleague.adobe.com/en/docs/commerce-operations/upgrade-guide/prepare/prerequisites#:~:text=Upgrade%20Elasticsearch

You have two options:

  • Continue using Elasticsearch 7, which is still supported by Magento 2.4.6.
  • Install the magento/module-elasticsearch-8 module to make Magento 2.4.6 compatible with Elasticsearch 8. You can do this by running the following command:
composer require magento/module-elasticsearch-8 --update-with-all-dependencies

If you use Adobe Commerce Cloud or your site does not show any products after reindexing the catalogsearch_fulltext indexer, you will need to update your Elasticsearch settings to enable the id_field_data field.
For Adobe Commerce Cloud, add the following configuration to your elasticsearch.yml file:

indices:
  id_field_data:
    enabled: true

For others, update your Elasticsearch settings to add or update the id_field_data field as shown below:

indices.id_field_data.enabled: true
2
  • Thank you so much. It's a save my time and working fine now after upgrade elastic module 8 May 2 at 8:50
  • @SagarDobariya You are most welcome!
    – Tu Van
    May 2 at 11:37
0

Adobe's Comerce Edition System Requirements shows that OpenSearch 2.5 is supported. I was running 2.11 .

[on Debian]

sudo apt list opensearch -a showed:

opensearch/stable,now 2.11.1 amd64 [installed]
opensearch/stable 2.11.0 amd64
opensearch/stable 2.10.0 amd64
opensearch/stable 2.9.0 amd64
opensearch/stable 2.8.0 amd64
opensearch/stable 2.7.0 amd64
opensearch/stable 2.6.0 amd64
opensearch/stable 2.5.0 amd64

Perform a downgrade install:
sudo apt install opensearch=2.5.0

Next, pin the release (see Gregor's apt pinning answer)
Create /etc/apt/preferences.d/opensearch with the following:

Package: opensearch
Pin: version 2.5.*
Pin-Priority: 999

It is crude, but opensearch will not start with any forward compatible indexes, ... thus
sudo rm -rvf /usr/share/opensearch/data/nodes/*
(perhaps I should have removed them before the downgrade, ...
curl -X DELETE 'http://localhost:9200/_all')

0

After searching around, I think that I am chasing a false negative error.

curl -XGET --insecure http://localhost:9200/_cat/indices?v generally shows the index in the error message, but with the version number incremented by one.

e.g. the error message will complain about magento2_product_1_v25 not having a uri, where the curl ... command will list magento2_product_1_v26 as existing.

I couldn't find any issue listing this symptom other than the advice:

Wait for changes to be applied

So either the search cluster is too fast or too slow, ... regardless, the admin "Index Management" page shows the index as ready.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.