Page 1 of 2 12 LastLast
Results 1 to 10 of 16

Thread: restoring grub2 record on each drive of a raid 5 or 6 array

  1. #1
    Join Date
    Feb 2009
    Beans
    30

    restoring grub2 record on each drive of a raid 5 or 6 array

    After expanding a raid 6 mdadm array from 4 to 5 drives, with --add and --grow, and before any updates to grub were made, computer was restarted.
    At boot, it now says something about an invalid arch independent ELF magic, and a grub rescue> prompt.

    Since the raid hosts /, I wonder if the ability of grub to assemble the md0 to get to /boot is now compromised. I have no idea how does that part work...


    What I have done, I booted from the "live usb" and have also found that as a part of my previous attempts to boot from the raid, one drive fell out (sdc), and --assemble --scan was only using 3 drives, ending up in degraded array. I have probably accidentally unplugged the drive, when checking cables out of desperation , but in any case - I have plugged the drive back in, and it was still not willing to join, complaining about superblock.

    Anyway, I have started the --manage --add, and it is resyncing now. When it is done, I am not sure what to do... I will attempt the restart, but something tells me it will fail again.
    Do I somehow need to fix the grub record first?

  2. #2
    Join Date
    Feb 2009
    Beans
    30

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    Well, as I was suspecting, it all has synced fine, but I now get this

    error: invalid arch independent ELF magic.
    grub rescue>

    I am not sure why, but I have a gut feeling now, that the ASRock motherboard (I have 6 SATA connectors on it) may be funny, and the 5th drive is not visible at boot. Once the OS is loaded, some drivers kick in, and see that connector. So, you can add a drive, expand your raid, but at reboot - it will always fail... Is that possible? I have 9700/U3S3 model...

    But even then, it must be possible to boot with degraded raid. There is this setting "bootdegraded=yes" somewhere, but I can not boot into the system. Besides, I think I have set it to "yes" on initial installation...
    Anyway, any ideas on this will be highly appreciated.

  3. #3
    Join Date
    Feb 2009
    Beans
    30

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    I have found this one - no resolution there. http://ubuntuforums.org/showthread.php?t=1678352
    And in another place, I have seen that grub (starting version 1.99 or something) is capable of booting from raid. But then there must be some part of the record, that indicates which drives to use. Mine all have the "fd" tag, a Linux raid autodetect flag.

  4. #4
    Join Date
    Jun 2009
    Location
    Chicago Suburbs
    Beans
    Hidden!
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    I think the arch error is most often an incompatible version of grub2 trying to boot a different version of grub2.

    With RAID you install grub2's boot loader to the root of the RAID which is where it is booted from.

    Someone posted this before.
    So to people with an Asrock Z77 Extreme4 motherboard: if you install Ubuntu, make sure the drives you are installing from and to are not connected to the Asmedia SATA ports!
    For info on UEFI boot install & repair - Updated Mar 2015:
    http://ubuntuforums.org/showthread.php?t=2147295
    Please use Thread Tools above first post to close thread when/if answered completely.







  5. #5
    Join Date
    Feb 2009
    Beans
    30

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    Quote Originally Posted by oldfred View Post
    I think the arch error is most often an incompatible version of grub2 trying to boot a different version of grub2.

    With RAID you install grub2's boot loader to the root of the RAID which is where it is booted from.

    Someone posted this before.
    This may be true in my case as well, as I suspect the bootloader needs to be updated with the new raid information. I do have /boot on the raid array, so grub needs to know how to assemble it. And, I suspect, that part should have been done separately... somehow... So, in a sense, I may have some "incompatibility". As for the port - I will look into that, but I am not sure what Asmedia ports are...

  6. #6
    Join Date
    Jun 2009
    Location
    Chicago Suburbs
    Beans
    Hidden!
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    Boot-Repair also works with RAID. It seems to know more about RAID than I do, but then anything does.

    Post the link to the BootInfo report that this creates. Is part of Boot-Repair:
    https://help.ubuntu.com/community/Boot-Info
    Boot Repair -Also handles LVM, GPT, separate /boot and UEFI dual boot.:
    https://help.ubuntu.com/community/Boot-Repair
    You can repair many boot issues with this or 'Create BootInfo' report (Other Options) & post the link it creates, so we can see your exact configuration and diagnose advanced problems.
    LighterWeight (Lubuntu based) Boot-RepairCD
    http://sourceforge.net/projects/boot-repair-cd/files/
    Full Ubuntu 13.04 liveDVD or USB Flash drive Installer with Boot-Repair included (for newer computers)
    https://help.ubuntu.com/community/LinuxSecureRemix
    For info on UEFI boot install & repair - Updated Mar 2015:
    http://ubuntuforums.org/showthread.php?t=2147295
    Please use Thread Tools above first post to close thread when/if answered completely.







  7. #7
    Join Date
    Feb 2009
    Beans
    30

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    Quote Originally Posted by oldfred View Post
    Boot-Repair also works with RAID. It seems to know more about RAID than I do, but then anything does.

    Post the link to the BootInfo report that this creates. Is part of Boot-Repair:
    https://help.ubuntu.com/community/Boot-Info
    Thanks, I have done that, and here is the URL: http://paste.ubuntu.com/6060799
    I have booted from the USB drive, I have also had one 2TB (1.8) drive removed (it is suspicious, I think it has failed), but since I have raid6, the other 4 drives are supposed to do the trick. Plus, I have a 3TB external USB drive plugged in.

    Any advice would be highly appreciated!

  8. #8
    Join Date
    Feb 2009
    Beans
    30

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    I have reviewed the result, and decided to remove the external drive to make it more readable. Plus, I want to mention, that sde is the flash drive I have booted from.
    Also, I have noticed, that md0 did not mount. So I have mounted it manually by

    sudo mdadm --assemble /dev/md0 /dev/sda1 /dev/sdb1 /dev/sdc1 /dev/sdd1 , and since it complained about starting the array, I then have forced it with
    sudo mdadm --run

    Then I ran another boot-repair, and got this: http://paste.ubuntu.com/6061265/
    Please, help.

  9. #9
    Join Date
    Jun 2009
    Location
    Chicago Suburbs
    Beans
    Hidden!
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    I see grub installed to the drives, but it needs to be install to md0 as I understand RAID. But there are so many different types of RAID and I do not understand differences.

    Also Boot-Repair posted this:
    dmraid packages needed
    User refused to install dmraid
    I think in your RAID is is not the fakeRAID but just md0?

    For RAID reinstall from live-CD/DVD/USB
    sudo apt-get install mdadm
    http://ubuntuforums.org/showthread.php?t=2022679
    "fakeRaid" with nVidia
    sudo mount /dev/mapper/isw_cdjacjeebj_VOLUME_0p1 /mnt
    sudo grub-install --root-directory=/mnt /dev/mapper/isw_cdjacjeebj_VOLUME_0
    For info on UEFI boot install & repair - Updated Mar 2015:
    http://ubuntuforums.org/showthread.php?t=2147295
    Please use Thread Tools above first post to close thread when/if answered completely.







  10. #10
    Join Date
    Feb 2009
    Beans
    30

    Re: restoring grub2 record on each drive of a raid 5 or 6 array

    Then, I went to the /etc/initramfs-tools/conf.d/mdadm and have changed BOOT_DEGRADED from false to true. Then with the help of the "repair" part of boot-repair, I have reinstalled grub2, into sda,b,c,d.

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •