27 January 2011

Making latest 2.6.x Linux kernel works with recent Linux distro

If you wanna compile new Linux kernel, let's say 2.6.35 onwards and you want it to run on fairly "old" distro, let's say CentOS 5.5, you might find it weird that it refuses to boot somewhere during root device mount?

Note: Wait, you say CentOS 5.5 is "old"? What I mean here is not "old" as "it's released 6-8 years ago", but old as "using quite old userspace tools"

What happen? You might think that you missed to enable (or possibly) include the filesystem driver in the initrd/initramfs. It's not. Thanks to various discussion archieve I found in Internet, it's a matter of enabling these two items in kernel config:
CONFIG_SYSFS_DEPRECATED=y
CONFIG_SYSFS_DEPRECATED_V2=y

If you're confused where to find them, it's in "General Setup". The item is named "enable deprecated sysfs features to support old userspace too". Then you're ready to plunge the new kernel into the distro.

regards,

Mulyadi

No comments:

How to execute multiple commands directly as ssh argument?

 Perhaps sometimes you need to do this: ssh user@10.1.2.3 ls It is easy understand the above: run ls after getting into 10.1.2.3 via ssh. Pi...