Skip to contentSkip to conversation

Docker: add more required kernel modules as RRECOMMENDS:${PN}

PATCH Koen Kooi 2 participants 2 messages Jul 31, 2025 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

Koen Kooi

author
#1 lore raw

Ping

Quoted 56 lines

Op 2 jul 2025, om 09:03 heeft Koen Kooi via lists.yoctoproject.org <[email protected]> het volgende geschreven:

With a very minimal image recipe that just pulls in docker, the daemon won't start due to missing modules, so add the missing ones.

The list of new modules was created by diffing the output of lsmod before installing all kernel-modules and the output after launching docker with all modules installed.

---

Changes since v1:
* Add kernel-module-veth, the docker daemon starts up just fine with the v1 patch, but launching an actual container fails due to missing veth.ko.

recipes-containers/docker/docker.inc | 13 ++++++++++++-

1 file changed, 12 insertions(+), 1 deletion(-)
recipes-containers/docker/docker.inc +0 -0
index 05a14f97..3a9d6865 100644
@@ -14,7 +14,18 @@ RDEPENDS:${PN} = "util-linux util-linux-unshare iptables \
                 "

RDEPENDS:${PN} += "virtual-containerd ${VIRTUAL-RUNTIME_container_runtime}"

recipes-containers/docker/docker.inc +12 -1
-RRECOMMENDS:${PN} = "kernel-module-dm-thin-pool kernel-module-nf-nat kernel-module-nf-conntrack-netlink kernel-module-xt-addrtype kernel-module-xt-masquerade"
+RRECOMMENDS:${PN} = "kernel-module-dm-thin-pool \
+                     kernel-module-nf-conntrack \
+                     kernel-module-nf-conntrack-netlink \
+                     kernel-module-nf-nat \
+                     kernel-module-nfnetlink \
+                     kernel-module-overlay \
+                     kernel-module-veth \
+                     kernel-module-x-tables \
+                     kernel-module-xt-addrtype \
+                     kernel-module-xt-conntrack \
+                     kernel-module-xt-masquerade \
+                    "

PROVIDES += "virtual/docker"

Signature · 10 lines
2.48.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9288): https://lists.yoctoproject.org/g/meta-virtualization/message/9288
Mute This Topic: https://lists.yoctoproject.org/mt/113944045/9418801
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
#2 lore raw

A well used ping!

I was busy upreving packages and testing for M3 and hadn't gotten to many merges.

Thanks for the change, this is now merged.

Bruce

Quoted 72 lines · Koen Kooi via lists.yoctoproject.org

Ping

Quoted 1 line

Op 2 jul 2025, om 09:03 heeft Koen Kooi via lists.yoctoproject.org

<[email protected]> het volgende geschreven:

Quoted 16 lines

With a very minimal image recipe that just pulls in docker, the daemon won't start due to missing modules, so add the missing ones.

The list of new modules was created by diffing the output of lsmod before installing all kernel-modules and the output after launching docker with all modules installed.

---

Changes since v1:
* Add kernel-module-veth, the docker daemon starts up just fine with the v1 patch, but launching an actual container fails due to missing veth.ko.

Review

Quoted 4 lines

recipes-containers/docker/docker.inc | 13 ++++++++++++-

1 file changed, 12 insertions(+), 1 deletion(-)
(quoted diff) +0 -0

b/recipes-containers/docker/docker.inc

recipes-containers/docker/docker.inc RDEPENDS:${PN} = "util-linux util-linux-unshare

Quoted 4 lines

index 05a14f97..3a9d6865 100644

recipes-containers/docker/docker.inc +0 -0
@@ -14,7 +14,18 @@ RDEPENDS:${PN} = "util-linux util-linux-unshare

iptables \

Quoted 2 lines
recipes-containers/docker/docker.inc +0 -0
                 "

RDEPENDS:${PN} += "virtual-containerd

${VIRTUAL-RUNTIME_container_runtime}"

Quoted 2 lines

-RRECOMMENDS:${PN} = "kernel-module-dm-thin-pool kernel-module-nf-nat

kernel-module-nf-conntrack-netlink kernel-module-xt-addrtype kernel-module-xt-masquerade"

Quoted 13 lines
recipes-containers/docker/docker.inc +12 -0
+RRECOMMENDS:${PN} = "kernel-module-dm-thin-pool \
+                     kernel-module-nf-conntrack \
+                     kernel-module-nf-conntrack-netlink \
+                     kernel-module-nf-nat \
+                     kernel-module-nfnetlink \
+                     kernel-module-overlay \
+                     kernel-module-veth \
+                     kernel-module-x-tables \
+                     kernel-module-xt-addrtype \
+                     kernel-module-xt-conntrack \
+                     kernel-module-xt-masquerade \
+                    "
Quoted 8 lines

PROVIDES += "virtual/docker"

--
2.48.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#9333):
https://lists.yoctoproject.org/g/meta-virtualization/message/9333
Mute This Topic: https://lists.yoctoproject.org/mt/113944045/1050810
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await thee
at its end
- "Use the force Harry" - Gandalf, Star Trek II