Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

grub-probe gets very confused if there are multiple partitions with pool components on a disk #16

Open
nwf opened this issue Jun 24, 2014 · 1 comment

Comments

@nwf
Copy link

nwf commented Jun 24, 2014

I created a bunch of GPT partition schemes with the EF02 boot loader partition (sdX1), a 32G partition (sdX2), and then a 1.4TB partition (sdX3) in the remaining space.

If I "zpool create -R /mnt -o ashift=12 r raidz2 /dev/sd[abcdefghijk]2", grub-probe is happy to report that /mnt/r is indeed of type zfs. If, however, I then also "zpool create -R /mnt -o ashift=12 z raidz2 /dev/sd[abcdefghijk]3", then grub-probe bails out with "unknown filesystem" and if I run with "-vv" it complains of a fletcher4 checksum failure. Running "zpool destroy z" makes everything happy again, running "zpool create ... z ..." makes things sad again.

I don't know if this is a grub-probe-specific bug or, more generally, a grub bug, as I have only now discovered it and have not been able to boot the system because of it.

ETA: Nope, not just grub-probe; having created the second zpool on these disks, grub can't boot and believes that "(hd0,gpt2)/" is an unknown filesystem. "(hd0,gpt3)/" on the other hand, still works.

@dweeezil
Copy link
Member

I've started recently converting most of my systems to native ZFS boot using the grub in Ubuntu 14.04 and also a hand-built version of the latest upstream grub for Fedora systems. I started having random failures such as "unknown filesystem", etc.

I wasn't terribly concerned about grub-probe and friends, but rather the inability to boot. The problem in my case was actually caused by the presence of more than one pool. When grub scans the devices (for search.fs_uuid or for any other filesystem operation) it is improperly adding all the devices into its idea of the pool and this can result in chaos.

I've worked up a patch have have submitted it to the grub problem tracker at https://savannah.gnu.org/bugs/index.php?42632. The fix for this problem is available at dweeezil/grub@e5d9983.

Please try my patch on your system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants