If a hard drive fails in a RAID 1 (Mirror), your data is still there, but your safety net is gone. Rebuilding means "teaching" a new, empty drive to become an exact copy of your remaining healthy drive.
Warning: This process requires absolute focus. You must correctly distinguish between your healthy drive (source) and the new empty drive (target). Mixing them up will result in total data loss.
Think of your RAID as two identical books. If one is destroyed, you buy a new one with empty pages. To restore your RAID, you must first draw the same lines (Partitioning) on the empty pages and then copy the text (Syncing) from the original book. Finally, you ensure the new book can be "read" at startup (Bootloader).
A RAID only works if the partitions on both disks are identical. We copy the "blueprint" from your healthy disk (e.g., sdb) to the new disk (e.g., sda).
Check which drive has partitions and which is empty:
This command copies the structure from sdb to sda and gives the new disk a unique ID:
Now that the new disk has the right "slots" (partitions), we tell the system to start copying the actual data into them.
Add the new partitions (sda1, sda3, etc.) to your existing RAID arrays (md0, md1):
The system is now busy copying. Do not turn off the server until this is finished:
A mirror copies your files, but not the hidden "start-up code" (Bootloader). Without this step, your server will not start if the other disk fails.
In the event of a technical defect, we will replace your hard drive free of charge. To do so, please open a hardware ticket in your PowerPanel.