Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[compose.yml] bitnami/mongodb crashes with Illegal instruction on Apple Silicon #204

Open
DarhkVoyd opened this issue Feb 5, 2024 · 0 comments

Comments

@DarhkVoyd
Copy link

Context

As per official deploy docs: here

docker compose up -d

This command will:

  • Start a MongoDB service named mongodb.
  • Start a service rocketchat, which will also wait for mongodb to be ready.

Description

When following the docs on Apple Silicon devices trying to run a RocketChat instance using docker compose. The Rocket.Chat container will run fine but the MongoDB will repeatedly crash unable to run the bitnami/mongodb container. The following error is displayed in the container logs:

2024-02-05 18:43:40 mongodb 13:13:40.83 INFO  ==> Initializing MongoDB...
2024-02-05 18:43:41 mongodb 13:13:41.01 INFO  ==> Deploying MongoDB from scratch...
2024-02-05 18:43:41 /opt/bitnami/scripts/libos.sh: line 346:   210 Illegal instruction     "$@" > /dev/null 2>&1

Solution

Apparently, it is due to QEMU not supporting emulating AVX instructions on ARM64 in Docker but only recently this issue has been somewhat solved. For now, this error can be solved by adding the following variable to the mongodb service environments for Apple Silicon devices in compose.ytml:

EXPERIMENTAL_DOCKER_DESKTOP_FORCE_QEMU: 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant