Tuesday, April 29, 2014

Linux Trivia: Grub Legacy 128 byte inode dependency

Documenting something that I tripped over while trying to fix a very old Linux system. 

Grub Legacy (0.97) is dependent on 128 byte inode sizes.  Newer systems use 256 byte inodes to store extended attributes.  This confuses grub causing it not to be able to boot system as well as cause boot loader installation to fail with odd error messages like can find /boot/grub/stage1.

Fortunately googling found that Kristian Reese had documented this in his own "knowledge base", somewhat like I'm doing here in a less organized fashion.

The file /boot/grub/stage1 not read correctly kristianreese.com knowledge base
The solution is to use mke2fs ... -I 128 ...to force a 128 byte inode size when re-making the "legacy" root file system that will be booted by grub "legacy".

Use tune2fs -l /dev/foo to see the current file system parameters.  Tip: Save tune2fs dump info someplace for import (root) file systems someplace off the system.

No comments: