DB2 failing to start (and causing test failures) on MacOS ARM with Podman
[ERROR] DOCKER> Error occurred during container startup, shutting down...
[ERROR] DOCKER> I/O Error [Unable to pull 'icr.io/db2_community/db2:12.1.0.0' from registry 'icr.io' : {"message":"no image found in manifest list for architecture \"arm64\", variant \"v8\", OS \"linux\""} (Internal Server Error: 500)]
I'm surprised we don't have an issue for this already, since I ran all our tests on Mac a few years ago, but I can't find one. It seems unlikely that DB2 used to pass on ARM and started failing, and I've confirmed we haven't removed a guard in the pom. It might be that M4 fails but earlier ARM processors pass. I don't know if it's an ARM+Podman issue, or it fails with Docker as well. The following integration tests fail on my Mac.
integration-tests/jpa-db2integration-tests/hibernate-reactive-db2integration-tests/reactive-db2-client
https://github.com/quarkusio/quarkus/issues/33104 is tracking a different issue (not ARM), but the solution in https://github.com/quarkusio/quarkus/issues/33104#issuecomment-3431735731 might help.
To reproduce:
- Remove the guards which disable the tests (!)
- Run
mvn clean verify -Dtest-containers -Dstart-containers -f integration-tests/jpa-db2
/cc @edeandrea (container-image), @geoand (container-image), @mswatosh (db2)
@holly-cummins from the error message, it seems there are no image available for the architecture? I'm not sure there's something we can do about it on our side?
AFAIK Mac ARM is able to run x86 container images. The problem here is that podman (?) is aborting after failing to retrieve the arm64 image, whereas we'd want it to retrieve the x86 image and proceed with the test run.
I'm not sure we can do something for Quarkus users, indeed, but I'd expect we can do something to make our own CI build pass, at least?
AFAIK Mac ARM is able to run x86 container images
Apparently one needs to install qemu-user-static on the podman machine in order to do that with podman: https://medium.com/@guillem.riera/podman-machine-setup-for-x86-64-on-apple-silicon-run-docker-amd64-containers-on-m1-m2-m3-bf02bea38598
@beikov might know more... if he uses podman? I guess docker is more likely.
With the latest podman, I can confirm that you can run most amd64 images just fine with the Rosetta support on MacOS. The only caveat is, that if you don't have the image pulled already, you will have to add --platform linux/amd64 to the pull, because by default, it will look for an ARM image on M4.