[master/rhel7] Don't add redundant grub installs if stage1 is not on a RAID

David Shea dshea at redhat.com
Thu Jan 16 20:00:08 UTC 2014


On 01/16/2014 02:48 PM, David Shea wrote:
>>> - else:
>>> -                    # target is /boot device and /boot is raid, so 
>>> install
>>> -                    # grub to each of /boot member partitions
>>> -                    stage1dev = stage2dev
>> I think we still support this case via kickstart, so we can't just drop
>> the ability to install the bootloader to the first sector of the stage2
>> device.
>
> That would still work, it would just be using the md device as the 
> target instead of doing separate grub2-installs to each component of 
> the array. Does grub2 need the actual partition devices?

To clarify, since this is the code that I'm trying to remove: the block 
above was needed because the behavior any time that stage2 was an array 
was to do separate grub2 invocations for each member of stage2. And that 
might be necessary, I don't know. But the code makes the assumption that 
stage1 is either the disk of one of the array components or the same as 
the stage2 array. Another way I thought of going about it was to only 
change the above else block to elif self.stage1_device == 
self.stage2_device, and then have an else: stage1dev = 
self.stage1_device. That would keep the separate grub2-installs but not 
assume that stage1 is always either the disk stage2 is on or the same 
partition.


More information about the anaconda-patches mailing list