yade container image 20.04 can't run on centos
Two virtual machines were build, one installed ubuntu 20.04, the other installed centos 7.9.
go 1.16.2 and singularity 3.7 were both installed in the two systems.
Make a def file named yade.def:
BootStrap: docker
From: registry.
Then build a singularity container:
sudo singularity build yade.sif yade.def
Run:
singularity exec yade.sif yade -n --test
On the ubuntu system, all test passed.
But on the centos system, a error occured:
Traceback (most recent call last):
File "/usr/bin/yade", line 144, in <module>
import yade
File "/usr/lib/
from yade import boot
ImportError: libQt5Core.so.5: cannot open shared object file: No such file or directory
Would you mind to find reasons of the error ? Why the same container run differently on the two systems ?
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- Yade Edit question
- Assignee:
- No assignee Edit question
- Last query:
- 2021-03-26
- Last reply:
- 2021-03-26
Hi,
Thank you for reporting.
I'm afraid it is a question for singularity/
Do you mean that building the sif from docker-
How does it go if you try to run tests directly with docker-
If you get same error then it would eliminate singularity as a source of the problem.
Also I'm curious about why you used "sudo" for the singularity build command.
Regards
Bruno
quanm qiu (quanm) said : | #2 |
Thanks for your reply.
I installed a host with centos 7.9 ISO image. Within the centos host, run :
docker run -it registry.
Unable to find image 'registry.
Trying to pull repository registry.
ubuntu20.04: Pulling from registry.
04a5f4cda3ee: Pull complete
ff496a88c8ed: Pull complete
0ce83f459fe7: Pull complete
cd27bc7d342d: Pull complete
74e2837b3322: Pull complete
Digest: sha256:
Status: Downloaded newer image for registry.
root@af9bf95508
Using python version: 3.8.5 (default, Jan 27 2021, 15:41:15)
[GCC 9.3.0]
Traceback (most recent call last):
File "/usr/bin/yade", line 103, in <module>
import yade.tests
File "/usr/lib/
from yade import boot
ImportError: libQt5Core.so.5: cannot open shared object file: No such file or directory
I got the same problem when using docker directly. So it's not singularity's problem.
Should I ask a question in the docker's forum or singularity's forum?
By the way, singularity need root privilege when building a image.
Thanks.
quanm qiu (quanm) said : | #3 |
Finally, I found source of the problem is kernel version.
The kernel needs to be at least 3.15 "Qt 5.10 uses the renameat2 system call which is only available since kernel 3.15"
See: https:/
After upgrade centos kernel version from 3.10 to 5.11, the error "error while loading shared libraries: libQt5Core.so.5: cannot open shared object file: No such file or directory" disappeared.
But I can't upgrade kernel version of the Supercomputer. I have to use another dirty solution, add a command to the singularity image .def file:
strip --remove-
Then the problem solved.
Wow! Thanks for solution. It might help others.
Another solution should be to use an older linux version [1]. They all have updated version if you use "yadedaily " instead of "yade".
Regards
Bruno
[1] https:/
Can you help with this problem?
Provide an answer of your own, or ask quanm qiu for more information if necessary.