Docker Community Forums

Share and learn in the Docker community.

Support for 32-bit images / containers on 64-bit hosts


(Stefanseefeld) #1

What is the status of support for 32-bit (x86) containers on 64-bit (x86_64) hosts ?

Is this supported at all ? Any advice on how to build and run such images ?


(Jeff Anderson) #2

Since the Linux x86_64 kernel can run 32-bit processes, running them in docker works just fine.

There are some x86 32-bit images out on the docker hub. For example, someone in the community has created these images: https://hub.docker.com/u/i686/

For example: docker run --rm -it i686/ubuntu bash


(Anton66) #3

If I run the following command…

 docker run --rm -it i686/ubuntu bash
 root@48d938458bb8:/# uname -m

I get the following output:

 x86_64

So it seems to me it is not a x86 32-bit image.


(Timothee "TTimo" Besset) #4

The kernel is your host’s kernel. That’s why you see x86_64 here, your container may still be 32 bit.

I’m not aware of a canonical way to check for a 32 or 64 bit container. I would normally run file /bin/bash, or check for the presence of /lib/x64_64-linux-gnu/