Short demonstration of raid10 with btrfs

Short demonstration of modern software raid options using btrfs. In this example raid10 is used to show what happens when a whole disc is lost. We use common btrfs commands to repare the raid10 architecture and as a result can see that no data is lost.

The demonstration shows all current filesystems btrfs filesystem show && lsblk. Then the partition is mounted by mounting any of the drives that are part of the raid. /dev/sdd till /dev/sdg are part of the raid10 configuration. In the mounted partition we see a 862 megabyte file. We override /dev/sdd with random bits dd if=/dev/urandom of=/dev/sdd. When we query btrfs to list the filesystems it shows the drive is missing. By mounting the drive with the -o degraded we can restore the partition. Even though one disc is missing we can still use it although is really unrecommended.