Bug#590742: grub-pc: savedefault doesn't work on mdraid

Vladimir 'φ-coder/phcoder' Serbinenko phcoder at gmail.com
Sun Nov 14 15:42:06 UTC 2010


severity 590742 low
thanks

On 07/29/2010 12:47 AM, Mario 'BitKoenig' Holbe wrote:
> Package: grub-pc
> Version: 1.98+20100710-1
>
> Hello,
>
> savedefault doesn't work on Linux Software-RAID raid1. Well, at least I
> guess it's because of the RAID.
>   
Savedefault doesn't work on RAID, LVM or ZFS. It's on purpose to avoid
potential damage like desynchronisation of an array. It may be changed
in the future but safety is mostly important, so until we're confident
that the writing functions can do no harm. I've documented it upstream
> The system in question has /boot on ext2 on md raid1 (degraded) on GPT
> disk partitions.
>
> I don't know whether write to raid1 is supposed to work. However, what
> really takes me aback is that save_env doesn't give an error - I think
> it should do that at least when it doesn't save.
> Actually, I'm a little bit nervous due to the missing error message
> because there it a chance that it does in fact write - somewhere.
>
>   
No damage has come to any of your disks. No write was attempted.
> $ grep boot /proc/mounts
> /dev/md0 /boot ext2 rw,nosuid,nodev,noexec,relatime 0 0
> $ grep -A2 ^md0 /proc/mdstat
> md0 : active raid1 sda2[0] sdb2[1]
>       240832 blocks [3/2] [UU_]
>
> $
>
> savedefault works on another system with the same package version,
> without raid1, with a MBR disk and /boot on the rootfs. I created the
> grubenv file the same way on both systems via grub-editenv create, both
> systems have GRUB_SAVEDEFAULT=true, GRUB_DEFAULT=saved, and an uptodate
> grub.cfg with savedefault in the menuentries.
>
> The system in question *reads* grubenv - when I set it to another
> menuentry with grub-set-default grub respects this on boot and selects
> the other menuentry.
>
> The differences I see (despite different CPU, RAM, ...) are GPT, raid1,
> and /boot on a separate filesystem. I suspect raid1 to be the most
> relevant difference here :)
>
> On both systems I tried
> grub> cat /grub/grubenv		(/boot/grub/grubenv on the working one)
> ...
> grub> saved_entry=foo
> grub> save_env saved_entry
> grub> cat /grub/grubenv
> ...
>
> On the working system the second cat reflects the change. On the system
> in question, grubenv's content didn't change.
>
>
> regards
>    Mario
>   
>
>
> _______________________________________________
> Pkg-grub-devel mailing list
> Pkg-grub-devel at lists.alioth.debian.org
> http://lists.alioth.debian.org/mailman/listinfo/pkg-grub-devel


-- 
Regards
Vladimir 'φ-coder/phcoder' Serbinenko


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 294 bytes
Desc: OpenPGP digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-grub-devel/attachments/20101114/6455f8a3/attachment-0001.pgp>


More information about the Pkg-grub-devel mailing list