dbhi / qus

qemu-user-static (qus) and containers, non-invasive minimal working setups

Home Page:https://dbhi.github.io/qus

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

No matching manifest for linux/arm64/v8

joserick opened this issue · comments

Hello,

Could you counsel me what am I doing wrong?

~$ uname -a
Linux ubuntu 5.4.0-1030-raspi Ubuntu aarch64 aarch64 aarch64 GNU/Linux

~$ docker run --rm --privileged aptman/qus -s -- -p x86_64
cat ./qemu-binfmt-conf.sh | sh -s -- --path=/qus/bin -p x86_64 --suffix -static
Setting /qus/bin/qemu-x86_64-static as binfmt interpreter for x86_64

~$ docker run --rm -it odoo
docker: no matching manifest for linux/arm64/v8 in the manifest list entries.

Docker, by default, tries to find a tag which matches your host. When you don't specify it, it tries to consider it to be a manifest, or it tries to use the latest. In this case, it is saying that neither the manifest nor the latest are for arm64. Precisely, those are for x86-64, and that's why you are using qus. So far, all good and expected.

Given that explanation, I think that you might be getting a warning, not an actual error. I tried executing it on my x86-64 workstation:

$ docker run --rm -it odoo
# Several seconds later, I get
Database connection failure: could not translate host name "db" to address: Name or service not known

Therefore, it is possible that your image is being properly executed after showing that warning, but you did not let it run long enough for showing the database failure. The db failure seems to be unrelated to qus, but due to some missing option/envvar/param that you should pass to the container. Can you please confirm whether you terminated the execution of the container with Ctrl+C or did it exit automatically?

I suggest trying the following:

$ docker run --rm -it odoo bash
# You might get the docker manifest warning here
odoo@aeaae9761a10:/$ exit

If that works, it means the qus is working as expected and the warning is negligible. You should only care about the db configuration for the tool (it seems to be an ERP).

If the previous test does still not work, you should be able to run the container by specifying the full image name. E.g. docker run --rm -it odoo:latest.

Note that using QEMU makes execution 5-10 times slower, and some images are known to have issues with clock time (see #6). Hence, please, be patient and let commands run for at least 30s before considering them to be hung.

Thanks for your reply,

The error of the missing database is because it uses another container for storage, called "postgresql" but apparently in my case it does not reach that, it's more when I directly execute the "pull" I get the same error/warning, which It does not allow the process to continue since in my opinion when the message appears it stops immediately:

~$ docker pull odoo:latest
latest: Pulling from library/odoo
no matching manifest for linux/arm64/v8 in the manifest list entries
~$

But you didn't get this error at any time, so the problem is that in my case it is not detecting the qus or it was not installed correctly?... Which would not make sense since I download ubuntu x86-64 (docker pull amd64/ubuntu) without problems; it will have something to do with "find a tag that matches your host" or the "manifest"?

Updated:
Error running amd64/ubuntu

~$ docker run --rm -it amd64/ubuntu bash
standard_init_linux.go:211: exec user process caused "exec format error"

I succeeded, apparently I just had to add "--platform amd64" to the "docker pull" to make it ignore the manifest:

~$ docker pull --platform amd64 odoo:latest

And then I ran "qus" again to run the image without the error "exec format error" and it worked.
Now yes, to work :)

Thanks for creating this wonderful repository!

But you didn't get this error at any time, so the problem is that in my case it is not detecting the qus or it was not installed correctly?...

I didn't get the error because I was doing the tests on an x86-64 workstation, not an arm device.

Which would not make sense since I download ubuntu x86-64 (docker pull amd64/ubuntu) without problems;

Pulling images is independent of the architecture. That will always work. The problem, if exists, is when trying to create a container and run something in it.

Error running amd64/ubuntu

This seems as the error you get when you did not configure qus before. Is that the case?

I succeeded, apparently I just had to add "--platform amd64" to the "docker pull" to make it ignore the manifest:

Interesting... I did not see this issue before. I had seen the warning, but not the requirement to specify the platform.

Anyway, I'm glad it worked in the end! Thank you for using this project/repo! ❤️