Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
@ 2025-08-18 13:24 Fiona Klute via buildroot
  2025-08-19  3:53 ` Christian Stewart via buildroot
  0 siblings, 1 reply; 8+ messages in thread
From: Fiona Klute via buildroot @ 2025-08-18 13:24 UTC (permalink / raw)
  To: buildroot; +Cc: Christian Stewart, Fiona Klute (WIWA)

From: "Fiona Klute (WIWA)" <fiona.klute@gmx.de>

Without systemd package/docker-engine requires another way to mount
/sys/fs/cgroup, so far unconditionally provided by
BR2_PACKAGE_CGROUPFS_MOUNT for cgroup v1. However, it is preferable to
use cgroup v2 if possible. Whether Docker can use cgroup v2 depends on
the kernel version, the Docker documentation lists the requirement as
"v4.15 or later (v5.2 or later is recommended)" [1].

Select BR2_PACKAGE_CGROUPFS_V2_MOUNT instead of
BR2_PACKAGE_CGROUPFS_MOUNT if the kernel headers match the recommended
version.

[1] https://docs.docker.com/engine/containers/runmetrics/#running-docker-on-cgroup-v2

Signed-off-by: Fiona Klute (WIWA) <fiona.klute@gmx.de>
---
I noticed Docker was unconditionally pulling in
BR2_PACKAGE_CGROUPFS_MOUNT while investigating a Docker warning about
memory cgroup not being available, and indeed my kernel config has
CONFIG_MEMCG enabled, but not the "highly discouraged" (to quote its
kernel config description) CONFIG_MEMCG_V1. Switching to v2 on
sufficiently recent kernels seems equally highly preferable.

I'm not sure if package/moby-buildkit should be adjusted to match so
the dependencies won't conflict. Current Buildkit definitely works
with cgroup v2, but the packaged version is fairly old.

 package/docker-engine/Config.in | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/package/docker-engine/Config.in b/package/docker-engine/Config.in
index 6338eeeef1..d591ee4e3b 100644
--- a/package/docker-engine/Config.in
+++ b/package/docker-engine/Config.in
@@ -7,7 +7,8 @@ config BR2_PACKAGE_DOCKER_ENGINE
 	depends on BR2_USE_MMU # containerd
 	depends on BR2_PACKAGE_LIBSECCOMP_ARCH_SUPPORTS # libseccomp
 	depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_17 # libseccomp
-	select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD # runtime dependency
+	select BR2_PACKAGE_CGROUPFS_V2_MOUNT if !BR2_PACKAGE_SYSTEMD && BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
+	select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD && !BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
 	select BR2_PACKAGE_CONTAINERD # runtime dependency
 	select BR2_PACKAGE_HOST_GO
 	select BR2_PACKAGE_IPTABLES # runtime dependency
-- 
2.50.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
  2025-08-18 13:24 [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd Fiona Klute via buildroot
@ 2025-08-19  3:53 ` Christian Stewart via buildroot
  2025-08-24  9:33   ` Romain Naour via buildroot
  0 siblings, 1 reply; 8+ messages in thread
From: Christian Stewart via buildroot @ 2025-08-19  3:53 UTC (permalink / raw)
  To: Fiona Klute; +Cc: buildroot

Hi Fiona,

On Mon, Aug 18, 2025 at 6:24 AM Fiona Klute <fiona.klute@gmx.de> wrote:
>
> From: "Fiona Klute (WIWA)" <fiona.klute@gmx.de>
>
> Without systemd package/docker-engine requires another way to mount
> /sys/fs/cgroup, so far unconditionally provided by
> BR2_PACKAGE_CGROUPFS_MOUNT for cgroup v1. However, it is preferable to
> use cgroup v2 if possible. Whether Docker can use cgroup v2 depends on
> the kernel version, the Docker documentation lists the requirement as
> "v4.15 or later (v5.2 or later is recommended)" [1].
>
> Select BR2_PACKAGE_CGROUPFS_V2_MOUNT instead of
> BR2_PACKAGE_CGROUPFS_MOUNT if the kernel headers match the recommended
> version.
>
> [1] https://docs.docker.com/engine/containers/runmetrics/#running-docker-on-cgroup-v2
>
> Signed-off-by: Fiona Klute (WIWA) <fiona.klute@gmx.de>
> ---
> I noticed Docker was unconditionally pulling in
> BR2_PACKAGE_CGROUPFS_MOUNT while investigating a Docker warning about
> memory cgroup not being available, and indeed my kernel config has
> CONFIG_MEMCG enabled, but not the "highly discouraged" (to quote its
> kernel config description) CONFIG_MEMCG_V1. Switching to v2 on
> sufficiently recent kernels seems equally highly preferable.
>
> I'm not sure if package/moby-buildkit should be adjusted to match so
> the dependencies won't conflict. Current Buildkit definitely works
> with cgroup v2, but the packaged version is fairly old.
>
>  package/docker-engine/Config.in | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/package/docker-engine/Config.in b/package/docker-engine/Config.in
> index 6338eeeef1..d591ee4e3b 100644
> --- a/package/docker-engine/Config.in
> +++ b/package/docker-engine/Config.in
> @@ -7,7 +7,8 @@ config BR2_PACKAGE_DOCKER_ENGINE
>         depends on BR2_USE_MMU # containerd
>         depends on BR2_PACKAGE_LIBSECCOMP_ARCH_SUPPORTS # libseccomp
>         depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_17 # libseccomp
> -       select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD # runtime dependency
> +       select BR2_PACKAGE_CGROUPFS_V2_MOUNT if !BR2_PACKAGE_SYSTEMD && BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
> +       select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD && !BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
>         select BR2_PACKAGE_CONTAINERD # runtime dependency
>         select BR2_PACKAGE_HOST_GO
>         select BR2_PACKAGE_IPTABLES # runtime dependency
> --
> 2.50.1
>

LGTM

Reviewed-by: Christian Stewart <christian@aperture.us>

Minor point, even if the kernel is at least 5.4, the old cgroup v1
format might still be enabled by a kernel argument, or the "hybrid"
which has both. But there is no way to know what runtime kernel
arguments will be set on the Buildroot side, so we will have to assume
people will migrate to either "hybrid" or "v2" when using Docker,
which is acceptable as it's been the default in all major distros for
quite a while now.

Thanks,
Christian Stewart
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
  2025-08-19  3:53 ` Christian Stewart via buildroot
@ 2025-08-24  9:33   ` Romain Naour via buildroot
  2025-08-25 10:24     ` Fiona Klute via buildroot
  0 siblings, 1 reply; 8+ messages in thread
From: Romain Naour via buildroot @ 2025-08-24  9:33 UTC (permalink / raw)
  To: Christian Stewart, Fiona Klute; +Cc: buildroot

Hello Fiona, Christian,

Le 19/08/2025 à 05:53, Christian Stewart via buildroot a écrit :
> Hi Fiona,
> 
> On Mon, Aug 18, 2025 at 6:24 AM Fiona Klute <fiona.klute@gmx.de> wrote:
>>
>> From: "Fiona Klute (WIWA)" <fiona.klute@gmx.de>
>>
>> Without systemd package/docker-engine requires another way to mount
>> /sys/fs/cgroup, so far unconditionally provided by
>> BR2_PACKAGE_CGROUPFS_MOUNT for cgroup v1. However, it is preferable to
>> use cgroup v2 if possible. Whether Docker can use cgroup v2 depends on
>> the kernel version, the Docker documentation lists the requirement as
>> "v4.15 or later (v5.2 or later is recommended)" [1].
>>
>> Select BR2_PACKAGE_CGROUPFS_V2_MOUNT instead of
>> BR2_PACKAGE_CGROUPFS_MOUNT if the kernel headers match the recommended
>> version.
>>
>> [1] https://docs.docker.com/engine/containers/runmetrics/#running-docker-on-cgroup-v2
>>
>> Signed-off-by: Fiona Klute (WIWA) <fiona.klute@gmx.de>
>> ---
>> I noticed Docker was unconditionally pulling in
>> BR2_PACKAGE_CGROUPFS_MOUNT while investigating a Docker warning about
>> memory cgroup not being available, and indeed my kernel config has
>> CONFIG_MEMCG enabled, but not the "highly discouraged" (to quote its
>> kernel config description) CONFIG_MEMCG_V1. Switching to v2 on
>> sufficiently recent kernels seems equally highly preferable.
>>
>> I'm not sure if package/moby-buildkit should be adjusted to match so
>> the dependencies won't conflict. Current Buildkit definitely works
>> with cgroup v2, but the packaged version is fairly old.
>>
>>  package/docker-engine/Config.in | 3 ++-
>>  1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/package/docker-engine/Config.in b/package/docker-engine/Config.in
>> index 6338eeeef1..d591ee4e3b 100644
>> --- a/package/docker-engine/Config.in
>> +++ b/package/docker-engine/Config.in
>> @@ -7,7 +7,8 @@ config BR2_PACKAGE_DOCKER_ENGINE
>>         depends on BR2_USE_MMU # containerd
>>         depends on BR2_PACKAGE_LIBSECCOMP_ARCH_SUPPORTS # libseccomp
>>         depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_17 # libseccomp
>> -       select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD # runtime dependency
>> +       select BR2_PACKAGE_CGROUPFS_V2_MOUNT if !BR2_PACKAGE_SYSTEMD && BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
>> +       select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD && !BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
>>         select BR2_PACKAGE_CONTAINERD # runtime dependency
>>         select BR2_PACKAGE_HOST_GO
>>         select BR2_PACKAGE_IPTABLES # runtime dependency
>> --
>> 2.50.1
>>
> 
> LGTM
> 
> Reviewed-by: Christian Stewart <christian@aperture.us>
> 
> Minor point, even if the kernel is at least 5.4, the old cgroup v1
> format might still be enabled by a kernel argument, or the "hybrid"
> which has both. But there is no way to know what runtime kernel
> arguments will be set on the Buildroot side, so we will have to assume
> people will migrate to either "hybrid" or "v2" when using Docker,
> which is acceptable as it's been the default in all major distros for
> quite a while now.

BR2_PACKAGE_DOCKER_ENGINE is used by TestDockerComposeRunc and
TestDockerComposeCrun tests. But while this test uses
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_X86_64_CORE_I7_GLIBC_STABLE toolchain that
provide BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4, it still uses an old 4.19.262 kernel
(where cgroup v2 is probably missing).

With this patch applied, docker error out with:

docker: Error response from daemon: failed to create task for container: failed
to create shim task: OCI runtime create failed: runc create failed: unable to
start container process: error during container init: error setting cgroup
config for procHooks process: bpf_prog_query(BPF_CGROUP_DEVICE) failed: function
not implemented

Can you have a look at TestDockerComposeRunc and TestDockerComposeCrun?

Thanks!

Best regards,
Romain


> 
> Thanks,
> Christian Stewart
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
  2025-08-24  9:33   ` Romain Naour via buildroot
@ 2025-08-25 10:24     ` Fiona Klute via buildroot
  2025-08-26 10:18       ` Thomas Petazzoni via buildroot
  0 siblings, 1 reply; 8+ messages in thread
From: Fiona Klute via buildroot @ 2025-08-25 10:24 UTC (permalink / raw)
  To: Romain Naour, Christian Stewart
  Cc: Arnout Vandecappelle (Essensium/Mind), Thomas Petazzoni,
	buildroot

Hi Romain!

Am 24.08.25 um 11:33 schrieb Romain Naour:
> Hello Fiona, Christian,
> 
> Le 19/08/2025 à 05:53, Christian Stewart via buildroot a écrit :
>> Hi Fiona,
>>
>> On Mon, Aug 18, 2025 at 6:24 AM Fiona Klute <fiona.klute@gmx.de> wrote:
>>>
>>> From: "Fiona Klute (WIWA)" <fiona.klute@gmx.de>
>>>
>>> Without systemd package/docker-engine requires another way to mount
>>> /sys/fs/cgroup, so far unconditionally provided by
>>> BR2_PACKAGE_CGROUPFS_MOUNT for cgroup v1. However, it is preferable to
>>> use cgroup v2 if possible. Whether Docker can use cgroup v2 depends on
>>> the kernel version, the Docker documentation lists the requirement as
>>> "v4.15 or later (v5.2 or later is recommended)" [1].
>>>
>>> Select BR2_PACKAGE_CGROUPFS_V2_MOUNT instead of
>>> BR2_PACKAGE_CGROUPFS_MOUNT if the kernel headers match the recommended
>>> version.
>>>
>>> [1] https://docs.docker.com/engine/containers/runmetrics/#running-docker-on-cgroup-v2
>>>
>>> Signed-off-by: Fiona Klute (WIWA) <fiona.klute@gmx.de>
>>> ---
>>> I noticed Docker was unconditionally pulling in
>>> BR2_PACKAGE_CGROUPFS_MOUNT while investigating a Docker warning about
>>> memory cgroup not being available, and indeed my kernel config has
>>> CONFIG_MEMCG enabled, but not the "highly discouraged" (to quote its
>>> kernel config description) CONFIG_MEMCG_V1. Switching to v2 on
>>> sufficiently recent kernels seems equally highly preferable.
>>>
>>> I'm not sure if package/moby-buildkit should be adjusted to match so
>>> the dependencies won't conflict. Current Buildkit definitely works
>>> with cgroup v2, but the packaged version is fairly old.
>>>
>>>   package/docker-engine/Config.in | 3 ++-
>>>   1 file changed, 2 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/package/docker-engine/Config.in b/package/docker-engine/Config.in
>>> index 6338eeeef1..d591ee4e3b 100644
>>> --- a/package/docker-engine/Config.in
>>> +++ b/package/docker-engine/Config.in
>>> @@ -7,7 +7,8 @@ config BR2_PACKAGE_DOCKER_ENGINE
>>>          depends on BR2_USE_MMU # containerd
>>>          depends on BR2_PACKAGE_LIBSECCOMP_ARCH_SUPPORTS # libseccomp
>>>          depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_17 # libseccomp
>>> -       select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD # runtime dependency
>>> +       select BR2_PACKAGE_CGROUPFS_V2_MOUNT if !BR2_PACKAGE_SYSTEMD && BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
>>> +       select BR2_PACKAGE_CGROUPFS_MOUNT if !BR2_PACKAGE_SYSTEMD && !BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4 # runtime dependency
>>>          select BR2_PACKAGE_CONTAINERD # runtime dependency
>>>          select BR2_PACKAGE_HOST_GO
>>>          select BR2_PACKAGE_IPTABLES # runtime dependency
>>> --
>>> 2.50.1
>>>
>>
>> LGTM
>>
>> Reviewed-by: Christian Stewart <christian@aperture.us>
>>
>> Minor point, even if the kernel is at least 5.4, the old cgroup v1
>> format might still be enabled by a kernel argument, or the "hybrid"
>> which has both. But there is no way to know what runtime kernel
>> arguments will be set on the Buildroot side, so we will have to assume
>> people will migrate to either "hybrid" or "v2" when using Docker,
>> which is acceptable as it's been the default in all major distros for
>> quite a while now.
> 
> BR2_PACKAGE_DOCKER_ENGINE is used by TestDockerComposeRunc and
> TestDockerComposeCrun tests. But while this test uses
> BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_X86_64_CORE_I7_GLIBC_STABLE toolchain that
> provide BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4, it still uses an old 4.19.262 kernel
> (where cgroup v2 is probably missing).
> 
> With this patch applied, docker error out with:
> 
> docker: Error response from daemon: failed to create task for container: failed
> to create shim task: OCI runtime create failed: runc create failed: unable to
> start container process: error during container init: error setting cgroup
> config for procHooks process: bpf_prog_query(BPF_CGROUP_DEVICE) failed: function
> not implemented
> 
> Can you have a look at TestDockerComposeRunc and TestDockerComposeCrun?

It looks like the "kernel too old for toolchain" problem appeared 
before, in commit 521b6f85508ee9ab848b0b2ea1d36edaf1701bc1 that was the 
reason to use the "stable" Bootlin toolchain instead of "bleeding-edge". 
Earlier this year the stable toolchain was updated with headers 5.4 
(commit 947dbc92a20c5acea7882166cae7893e6ea661e1), so I think the 
reasonable solution here is to update the kernel. Looks like the kernel 
config needs to be adjusted for 5.4.x, I'll send a patch when I have the 
tests passing.

Another question is if it still makes sense to claim support for kernel 
versions < 5.4 and cgroup v1. Maybe it'd be better to simplify things 
and have "depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4" for all the 
Docker packages, or even remove package/cgroupfs-mount entirely and 
require all packages that need cgroups to use v2? There aren't that 
many, grepping for BR2_PACKAGE_CGROUPFS_MOUNT (other than Docker and 
Podman, which already works with either) there are package/moby-buildkit 
(definitely supports cgroupv2), package/libvirt (haven't checked, but 
I'd be extremely surprised if not), and package/balena-engine (no idea, 
this is the first time I've heard of it).

Best regards,
Fiona

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
  2025-08-25 10:24     ` Fiona Klute via buildroot
@ 2025-08-26 10:18       ` Thomas Petazzoni via buildroot
  2025-08-27 15:22         ` Romain Naour via buildroot
  0 siblings, 1 reply; 8+ messages in thread
From: Thomas Petazzoni via buildroot @ 2025-08-26 10:18 UTC (permalink / raw)
  To: Fiona Klute
  Cc: Romain Naour, Arnout Vandecappelle (Essensium/Mind),
	Christian Stewart, buildroot

On Mon, 25 Aug 2025 12:24:27 +0200
Fiona Klute <fiona.klute@gmx.de> wrote:

> It looks like the "kernel too old for toolchain" problem appeared 
> before, in commit 521b6f85508ee9ab848b0b2ea1d36edaf1701bc1 that was the 
> reason to use the "stable" Bootlin toolchain instead of "bleeding-edge". 
> Earlier this year the stable toolchain was updated with headers 5.4 
> (commit 947dbc92a20c5acea7882166cae7893e6ea661e1), so I think the 
> reasonable solution here is to update the kernel. Looks like the kernel 
> config needs to be adjusted for 5.4.x, I'll send a patch when I have the 
> tests passing.

Indeed, now that the stable Bootlin toolchains use 5.4 headers, all
tests should use >= 5.4 kernel versions.

> Another question is if it still makes sense to claim support for kernel 
> versions < 5.4 and cgroup v1. Maybe it'd be better to simplify things 
> and have "depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4" for all the 
> Docker packages, or even remove package/cgroupfs-mount entirely and 
> require all packages that need cgroups to use v2? There aren't that 
> many, grepping for BR2_PACKAGE_CGROUPFS_MOUNT (other than Docker and 
> Podman, which already works with either) there are package/moby-buildkit 
> (definitely supports cgroupv2), package/libvirt (haven't checked, but 
> I'd be extremely surprised if not), and package/balena-engine (no idea, 
> this is the first time I've heard of it).

Totally fine with this idea. I think it's OK to require a 5.4 kernel if
you want to run Docker.

Thomas
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
  2025-08-26 10:18       ` Thomas Petazzoni via buildroot
@ 2025-08-27 15:22         ` Romain Naour via buildroot
  2025-08-28  9:11           ` Peter Korsgaard
  0 siblings, 1 reply; 8+ messages in thread
From: Romain Naour via buildroot @ 2025-08-27 15:22 UTC (permalink / raw)
  To: Thomas Petazzoni, Fiona Klute
  Cc: Arnout Vandecappelle (Essensium/Mind), Christian Stewart,
	buildroot

Hello Fiona, Thomas, All,

Le 26/08/2025 à 12:18, Thomas Petazzoni a écrit :
> On Mon, 25 Aug 2025 12:24:27 +0200
> Fiona Klute <fiona.klute@gmx.de> wrote:
> 
>> It looks like the "kernel too old for toolchain" problem appeared 
>> before, in commit 521b6f85508ee9ab848b0b2ea1d36edaf1701bc1 that was the 
>> reason to use the "stable" Bootlin toolchain instead of "bleeding-edge". 
>> Earlier this year the stable toolchain was updated with headers 5.4 
>> (commit 947dbc92a20c5acea7882166cae7893e6ea661e1), so I think the 
>> reasonable solution here is to update the kernel. Looks like the kernel 
>> config needs to be adjusted for 5.4.x, I'll send a patch when I have the 
>> tests passing.
> 
> Indeed, now that the stable Bootlin toolchains use 5.4 headers, all
> tests should use >= 5.4 kernel versions.
> 
>> Another question is if it still makes sense to claim support for kernel 
>> versions < 5.4 and cgroup v1. Maybe it'd be better to simplify things 
>> and have "depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4" for all the 
>> Docker packages, or even remove package/cgroupfs-mount entirely and 
>> require all packages that need cgroups to use v2? There aren't that 
>> many, grepping for BR2_PACKAGE_CGROUPFS_MOUNT (other than Docker and 
>> Podman, which already works with either) there are package/moby-buildkit 
>> (definitely supports cgroupv2), package/libvirt (haven't checked, but 
>> I'd be extremely surprised if not), and package/balena-engine (no idea, 
>> this is the first time I've heard of it).
> 
> Totally fine with this idea. I think it's OK to require a 5.4 kernel if
> you want to run Docker.

Agree. If we really want to keep cgroupv1, we must at least add a specific test
to check if other packages (like docker) are still working with only cgroupv1.

I'm not sure it's worth the effort.

Best regards,
Romain


> 
> Thomas

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
  2025-08-27 15:22         ` Romain Naour via buildroot
@ 2025-08-28  9:11           ` Peter Korsgaard
  2025-08-29  9:15             ` Fiona Klute via buildroot
  0 siblings, 1 reply; 8+ messages in thread
From: Peter Korsgaard @ 2025-08-28  9:11 UTC (permalink / raw)
  To: Romain Naour
  Cc: Thomas Petazzoni, Fiona Klute, Christian Stewart, buildroot,
	Arnout Vandecappelle (Essensium/Mind)

>>>>> "Romain" == Romain Naour <romain.naour@smile.fr> writes:

Hi,

 >> Totally fine with this idea. I think it's OK to require a 5.4 kernel
 >> if you want to run Docker.

 > Agree. If we really want to keep cgroupv1, we must at least add a specific test
 > to check if other packages (like docker) are still working with only cgroupv1.

 > I'm not sure it's worth the effort.

I doubt it as well. Recently, systemd has also dropped cgroupv1 support:

https://mastodon.social/@pid_eins/115088165140443645

-- 
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd
  2025-08-28  9:11           ` Peter Korsgaard
@ 2025-08-29  9:15             ` Fiona Klute via buildroot
  0 siblings, 0 replies; 8+ messages in thread
From: Fiona Klute via buildroot @ 2025-08-29  9:15 UTC (permalink / raw)
  To: Peter Korsgaard, Romain Naour
  Cc: Thomas Petazzoni, Christian Stewart, buildroot,
	Arnout Vandecappelle (Essensium/Mind)

Am 28.08.25 um 11:11 schrieb Peter Korsgaard:
>>>>>> "Romain" == Romain Naour <romain.naour@smile.fr> writes:
> 
> Hi,
> 
>   >> Totally fine with this idea. I think it's OK to require a 5.4 kernel
>   >> if you want to run Docker.
> 
>   > Agree. If we really want to keep cgroupv1, we must at least add a specific test
>   > to check if other packages (like docker) are still working with only cgroupv1.
> 
>   > I'm not sure it's worth the effort.
> 
> I doubt it as well. Recently, systemd has also dropped cgroupv1 support:
> 
> https://mastodon.social/@pid_eins/115088165140443645
Thanks everyone, looks like there's strong consensus, I'll respin 
accordingly.

Best regards,
Fiona

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2025-08-29  9:15 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-18 13:24 [Buildroot] [PATCH 1/1] package/docker-engine: prefer cgroup v2 with kernel >=5.4 and no systemd Fiona Klute via buildroot
2025-08-19  3:53 ` Christian Stewart via buildroot
2025-08-24  9:33   ` Romain Naour via buildroot
2025-08-25 10:24     ` Fiona Klute via buildroot
2025-08-26 10:18       ` Thomas Petazzoni via buildroot
2025-08-27 15:22         ` Romain Naour via buildroot
2025-08-28  9:11           ` Peter Korsgaard
2025-08-29  9:15             ` Fiona Klute via buildroot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox