Linux Partitioning Question
-
Hello there. I took the LPIC 1 course with Don Pezet and Wes Bryant and it was excellent. I had a question regarding the correct way, or suggestions on how to partition your linux system, so in the event of a disk failure, issues, etc, your whole system will not be at risk. How many disks do you recommend?
Thank you,
Kareem S.
-
The easiest and most efficient path is to use two hard drives in a RAID 0 mirror. Most motherboards include RAID support these days, and RAID 0 mirrors the disk regardless of what operating system you run. If that is not an option, you could always script cloning your disks using
dd
or manually clone them using software like CloneZilla or GParted. I use the scripted approach on most of my Raspberry Pis as they don't support hardware RAID. -
You can do RAID 1 or RAID 0+1 on most motherboards. RAID 1 would be two hard drives. RAID 0+1 would be 4. If one hard drive fails, you can replace it. I like Western Digital Black Drives for performance and reliability.
I went out and found a refurbished HP server with SAS RAID controller for about $1200. I has a SD slot for VMWare 6 standalone. It is free to use standalone. You upgrade it to VMWare Essentials Kit and use VEEAM backup for the VM. It isn't cheap to do this around $1800-$2000. I run 7 Ubuntu servers on it including two Wordpress servers, DNS, DHCP, Programming server for Python and PHP. I setup IPv4 and IPv6 on it.
-
Linux software RAID works quite well, but keep in mind that RAID will not protect you from accidental deletions, just disk failure.
@Don-Pezet has the right idea but I believe he wanted to say RAID-1 (mirroring) instead of RAID-0 (striping).
Keep in mind that you will lose the capacity of at least one drive when you deploy RAID.
RAID 0: Striping. NOT REDUNDANT. Great choice when performance is more important than reliability (video editing working drive).
RAID 1: Mirroring. Capacity of one drive.
RAID 5: Striping with Parity: Minimum three drives. Capacity of number of drives - 1.
RAID 6: Same as RAID 5 but with two parity drives. Capacity of number of drives minus 2.
RAID 10: Striping + mirroring. Capacity of number of drives / 2.As Don suggested, RAID-1 is probably the right option.
Any properly paranoid shop will use both backups (protection from accidental deletions) and RAID (protection from disk failure).