r/kernel•
NamedBird

Impossible to compile an IPv6-only kernel? (IPv6 without IPv4)

While doing some kernel tweaking for a hobby project, i noticed that i cannot disable IPv4.
At least, disabling IPv4 also disables IPv6.
(Or rather, there seems to be no distinction between IPv4 and the Internet Protocol...)

Is there a specific reason for this?

Given that IPv4 is basically a legacy protocol right now, i expected it could just be disabled.
But if you want IPv6 support, you are basically required to also have IPv4 support in the kernel.

I would like to compile my Linux kernel with only IPv6 support.
Is this possible?

It would be useful for future-readiness testing or compiling tiny network capable kernels.

Posted Jul 6, 2025, 7:25 PM UTC

79
Loading comments…