translator
1,001
edits
m (Link to wikipedia) |
(extended) |
||
Line 99: | Line 99: | ||
= Btrfs RAID = | = Btrfs RAID = | ||
Btrfs | With Btrfs you no longer need to use ''mdadm'' to create mirrored volumes or to create RAIDs. This is already included in btrfs, and very easy to use. There are even advanced features bult in: | ||
* Add devices to the volume This will integrate a device into the mounted volume {{RootCmd|command=btrfs device add /dev/sdz7 /}} | |||
* Remove devices from the volume. This will not delete any data, but remove the device from the volume. Bevorehand all data will be copied to the remaining devices of the volume.{{RootCmd|command=btrfs device delete /dev/sdz8 /}} | |||
* Use devices with different sizes in one volume | |||
* Switch the volume between RAID levels | |||
* Convert data to different RAID levels | |||
* Do this while the volume is mounted and being used | |||
see [https://en.wikipedia.org/wiki/RAID RAID@wikipedia] | see [https://en.wikipedia.org/wiki/RAID RAID@wikipedia] | ||
== RAID 0 (Just a Bunch of Disks)== | == RAID 0 (not Just a Bunch of Disks)== | ||
Using one ore more devices to build a volume. This volume has the '''capacity of all the used devices together(1+2+3+4...)'''. This is an very easy way to expand your volume when you need more space. You even can add 2 or 3 devices at a time. When you want to replace a device, you can add the new device, then remove the old device. Btrfs will move all data as necessary. ''To distribute all data to all devices you may want to '''balance''' the volume.'' | Using one ore more devices to build a volume. This volume has the '''capacity of all the used devices together(1+2+3+4...)'''. This is an very easy way to expand your volume when you need more space. You even can add 2 or 3 devices at a time. When you want to replace a device, you can add the new device, then remove the old device. Btrfs will move all data as necessary. ''To distribute all data to all devices you may want to '''balance''' the volume.'' Btrfs will stripe the data to all devices. | ||
{{BoxWarning|If one device fails, everything is lost|Be aware that when one of the devices fails your complete volume will be lost}} | {{BoxWarning|If one device fails, everything is lost|Be aware that when one of the devices fails your complete volume will be lost}} | ||
Line 114: | Line 120: | ||
== RAID 1 (mirrored), 1C3, 1C4 == | |||
=== automatic repair === | === automatic repair === | ||
In order to preserve the integrity of the volume, Btrfs does separate CRC-checksums of metadata blocks and of data blocks. Every time a data block is read, the checksum is verified. When the checksum shows that the data is not good, Btrfs tries to get a good copy from the mirrored block. Then the bad block is written again with the good data from the mirrored block. This happens in background. The filesystem has been repaired, and this is logged into syslog. This can be forced by using btrfs scrub. | |||
== RAID 10 == | === RAID 10 (automatic) === | ||
When using enough devices, Btrfs will distribute all data, so that it not only is mirrored but also striped. | |||
== RAID 5 == | == RAID 5 == |