Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

stratboy's avatar

Mailisearch with sail - problems with database version

Hi, I just created another Laravel test site (I'm studying), but suddenly Mailisearch stopped working, and the following error pops up:

Error: Your database version (1.4.2) is incompatible with your current engine version (1.5.0).
To migrate data between Meilisearch versions, please follow our guide on https://www.meilisearch.com/docs/learn/update_and_migration/updating.

This issue now applies to all my Laravel installations, so it's not related to the last one. I tried to follow the suggested guide, but I can't because I simply don't have access to mailiseach terminal since the container is not running. Therefore, before getting crazy, I'm asking here:

  • Is it normal? I mean, I just installed Laravel with the usual curl command:
curl -s "https://laravel.build/[example-app]" | bash
  • Shouldn't it install something fully working? Should I wait some update from Laravel? What's going on here?
0 likes
3 replies
LaryAI's avatar
Level 58

It seems like you're encountering a version compatibility issue between Meilisearch's database and the engine. This can happen when the Meilisearch engine has been updated to a new version, but the data was created with an older version, leading to incompatibility.

Since you're using Laravel Sail, which is a Docker-based development environment, you should be able to access the Meilisearch terminal through Docker commands. Here's what you can do to resolve the issue:

  1. First, make sure all your Docker containers are running. You can check this with the following command:
docker ps
  1. If the Meilisearch container is not running due to the version conflict, you might need to force it to start. You can try starting it with the following command:
docker-compose up -d meilisearch

Replace meilisearch with the actual service name if it's different in your docker-compose.yml file.

  1. Once the Meilisearch container is running, you can access its terminal using the following command:
docker-compose exec meilisearch sh
  1. If you need to migrate your Meilisearch data to the new version, you will have to follow the migration guide provided by Meilisearch. This might involve exporting your data from the old version and importing it into the new version. The guide on their website should provide detailed instructions.

  2. If you don't need to keep the data and just want to start fresh with the new Meilisearch version, you can reset the Meilisearch container. Warning: This will delete all your existing data in Meilisearch. You can reset the container with the following commands:

docker-compose stop meilisearch
docker-compose rm meilisearch
docker-compose pull meilisearch
docker-compose up -d meilisearch

Again, replace meilisearch with the actual service name if it's different in your docker-compose.yml file.

  1. If you continue to have issues, you may want to specify the Meilisearch version in your docker-compose.yml file to ensure compatibility. You can do this by changing the image tag to a specific version that is compatible with your database version:
services:
  meilisearch:
    image: getmeili/meilisearch:v1.4.2
    # other configurations...

After making changes to your docker-compose.yml file, you'll need to stop and recreate the Meilisearch container:

docker-compose up -d --force-recreate meilisearch

Remember to replace v1.4.2 with the version that matches your database version or the version you want to use.

By following these steps, you should be able to resolve the version compatibility issue with Meilisearch in your Laravel Sail environment. If you continue to have problems, consider reaching out to the Meilisearch community or checking their GitHub issues for similar problems and solutions.

1 like
stratboy's avatar

By following all the Lary suggestions, I was able to solve the issue by changing the version in docker-compose from latest to 1.4.2. latest version is 1.5.0, which was released last week, and this was the reason why it didn't work.

Ok, but what if I wanted to use 1.5.0? I tried all the other docker solutions, but wasn't able to use v1.5.0. What's the reason why? Maybe I should also delete the mailisearch Volume? Then it would be automatically recreated? Or am I going to destroy everything?

Please or to participate in this conversation.