Skip to content

[bitnami/mongodb] Mongodb doesn't run on M1 Mac #40947

Open
@tclasen

Description

@tclasen

Name and Version

bitnami/mongodb:5.0.10-debian-11-r3

What architecture are you using?

arm64

What steps will reproduce the bug?

I'm actually trying to run the Bitnami helm chart for Mongodb running in minikube on a M1 Mac. But I can replicate the problem with: docker run --rm -it docker.io/bitnami/mongodb:5.0.10-debian-11-r3

What is the expected behavior?

I would like to see aarch64 (arm64) images published to dockerhub for 5.0.10 and newer versions of Mongo.

What do you see instead?

docker run --rm -it docker.io/bitnami/mongodb:5.0.10-debian-11-r3

WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
mongodb 20:51:20.14
mongodb 20:51:20.17 Welcome to the Bitnami mongodb container
mongodb 20:51:20.18 Subscribe to project updates by watching https://github.com/bitnami/containers
mongodb 20:51:20.20 Submit issues and feature requests at https://github.com/bitnami/containers/issues
mongodb 20:51:20.22
mongodb 20:51:20.24 INFO  ==> ** Starting MongoDB setup **
mongodb 20:51:20.35 INFO  ==> Validating settings in MONGODB_* env vars...

It hangs on this step forever. In the k8s template, the pod is restarted due to being detected as stuck and timed out.

I've tried to build these myself using the bitnami/containers repo, but I get the following error:

0.752 mongodb-shell-1.10.1-0-linux-arm64-debian-11.tar.gz: OK
1.540 yq-4.34.2-0-linux-arm64-debian-11.tar.gz: OK
1.697 wait-for-port-1.0.6-9-linux-arm64-debian-11.tar.gz: OK
1.814 render-template-1.0.5-7-linux-arm64-debian-11.tar.gz: OK
2.014 sha256sum: mongodb-5.0.18-1-linux-arm64-debian-11.tar.gz.sha256: no properly formatted SHA256 checksum lines found
Dockerfile:26

Additional information

According to the mongo forums the x86 binary requires the AVX CPU flag which isn't provided by the Rosetta x86 emulator, meaning it is expected that the x86 version of mongo would never be able to run on the aarch64 (arm64) architecture of a M1 Mac. https://www.mongodb.com/community/forums/t/mongodb-docker-container-not-starting-properly/160540

Metadata

Metadata

Labels

mongodbon-holdIssues or Pull Requests with this label will never be considered staletech-issuesThe user has a technical issue about an application

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions