Installing OS on a RAID system

Discussion in 'RAID Controllers and Host Bus Adapters' started by pettinz, May 22, 2018.

  1. pettinz

    pettinz Member

    Joined:
    May 1, 2018
    Messages:
    33
    Likes Received:
    0
    Hi,
    I thought to install Debian OS on a RAID 1 system. Now I read that I can install the OS making the RAID directly on the motherboard (hardware RAID I think) or during the installing process (software RAID I think), but I have a few questions...

    1) What happen if a disk will fail? I think that I can’t boot more so how can I change the failed drive and rebuild it?
    2) Is better to build the RAID directly on the motherboard or during the OS installing process?
    Soon I will change my motherboard to a new one. So
    3) Can I reuse the same RAID array on the new motherboard if I set up it on the older one (hardware RAID) ?

    I’m sorry if the questions can look stupid, but I don’t have clear ideas.
     
    #1
  2. EffrafaxOfWug

    EffrafaxOfWug Radioactive Member

    Joined:
    Feb 12, 2015
    Messages:
    556
    Likes Received:
    180
    Depends on your motherboard/SATA controller, but it's unlikely to be proper hardware RAID on most motherboards. Most SATA chipsets expose a pseudo-hardware RAID (often referred to as "fakeraid") that's actually just software RAID implemented by an OS driver (and primarily intended for windows).

    Need more info to be sure, but since you're using debian you probably want to set up mdadm software RAID within the OS install process; there are more advanced things like ZFS you can use but that sounds beyond the scope of things for now. mdadm offers a great deal of flexibility and resilience and, unlike "fakeraid", doesn't tie you into using a particular SATA controller.

    To answer your other points;
    1) If a disc fails, mdadm will notify you (although the specifics of this depends on how your OS will be set up). I have mdadm send me an email if a disc ever goes pop.
    3) Typically "fakeraid" is tied to a manufacturer so it can be a bit of a crapshoot as to whether you can take a disc/array from one system and have it work on another. mdadm softraid on the other hand just treats the disc like a bog-standard disc, so you can plug an mdadm array into any other box running linux and have it be recognised (faults notwithstanding). Anecdote time but I've got a "grandfather's axe" of an mdadm RAID array in one of my servers - it's been on three different motherboards and four different sets of SSDs over the years (not to mention metadata and filesystem upgrades).
     
    #2
    pettinz likes this.
  3. pettinz

    pettinz Member

    Joined:
    May 1, 2018
    Messages:
    33
    Likes Received:
    0
    Thank you for your exhaustive answer. If I have the OS setted up on a RAID 1 (of 2 SSD) that I created during the OS installation, I will able to boot the OS also if a SSD is broken?
     
    #3
  4. EffrafaxOfWug

    EffrafaxOfWug Radioactive Member

    Joined:
    Feb 12, 2015
    Messages:
    556
    Likes Received:
    180
    That can be a very big "it depends", depending on how you boot, thanks to UEFI being a not-very-well-thought-out protocol and not supporting booting from arbitrary devices.

    If you do regular BIOS/CSM boot, you can boot off an mdadm RAID1 array without any problem.

    UEFI boot however typically requires a FAT32 formatted DOS partition in order to boot, and mdadm doesn't present itself as such (unless you get a bit hacky), so you'll not be able to boot directly from an mdadm RAID1 under most circumstances. I've got a 512MB RAID1 array mounted at /boot and then two non-RAIDed FAT32 partitions that mount at /boot/efi (the one that's actually used for UEFI boot) and /boot/efi2. The files in /boot/efi don't change very often, but when they do you can just copy them to /boot/efi2.

    The UEFI BIOS is clever enough to spot that an EFI boot partition exists on both of the specified boot drives so even if one is removed, it should be able to automatically boot from the other one.
     
    #4
    Evan and pettinz like this.
  5. pettinz

    pettinz Member

    Joined:
    May 1, 2018
    Messages:
    33
    Likes Received:
    0
    Talking about UEFI, what do you suggest? As I said, soon I will change my motherboard and CPU. If I install the OS in UEFI mode, what will happen if I change the motherboard?
     
    #5
    Last edited: May 22, 2018
  6. EffrafaxOfWug

    EffrafaxOfWug Radioactive Member

    Joined:
    Feb 12, 2015
    Messages:
    556
    Likes Received:
    180
    Same as with changing the motherboard if it's installed in BIOS/CSM mode - it's an industry standard, so any board capable of booting UEFI should be able to boot the same discs/array transplanted from another device.
     
    #6
  7. darklight

    darklight New Member

    Joined:
    Oct 20, 2015
    Messages:
    13
    Likes Received:
    4
    I would simply install OS on an SD card or USB drive and use the main RAID for the applications or data. It is the main common scenario.
     
    #7
  8. pettinz

    pettinz Member

    Joined:
    May 1, 2018
    Messages:
    33
    Likes Received:
    0
    No I can’t I need more space for software and data and I need redundancy for this data
     
    #8
  9. i386

    i386 Well-Known Member

    Joined:
    Mar 18, 2016
    Messages:
    1,222
    Likes Received:
    273
    1) With hardware raid you can boot without problems, your os doesn't know about the failed disk, but the controller knows and the alarm signal can be heard.
    2.) With hardware raid you need to create before installing the os. After creating the logical volume you can move the controller to other systems and use that volume for the os.
    3.) see 2.)
     
    #9
Similar Threads: Installing RAID
Forum Title Date
RAID Controllers and Host Bus Adapters BSOD after installing LSI 9260-8i Mar 27, 2015
RAID Controllers and Host Bus Adapters Poor RAID-6 performance with Adaptec 7-series Jun 14, 2018
RAID Controllers and Host Bus Adapters Performance advice (3x Slow-drives - RAID5) on LSI RAID for ESXI Jun 14, 2018
RAID Controllers and Host Bus Adapters SSD Endurance RAID 5 vs RAID 10 Jun 13, 2018
RAID Controllers and Host Bus Adapters Guidance on RAID 10 Multimedia Server Array on Adaptec + SSDs Jun 8, 2018

Share This Page