Since most of the business getting migrated to IT infrastructure, the growth in size of data is getting high. The advancement in hardware technology though is pretty impressive; it fails to scale/reuse existing hardware. It creates high demand on companies to move new advanced hardware with high storage capabilities.
In order to overcome this in 1987, David Patterson, Garth A. Gibson, and Randy Katz at the University of California, Berkeley came up with a new storage virtualization concept. This concept provides way to combine multiple small inexpensive disks on demand into single logical unit. This concept is called RAID (Redundant Array of Inexpensive Disks). Marketers representing industry RAID manufacturers later reinvented the term to describe a redundant array of independent disks.
Types of RAID
1. RAID 0 - Block-level striping without parity or mirroring.
2. RAID 1 - Mirroring without parity or striping.
3. RAID 2 - Bit-level striping with dedicated Hamming-code parity.
4. RAID 3 - Byte-level striping with dedicated parity.
5. RAID 4 – Block-level striping with dedicated parity.
6. RAID 5 - Block-level striping with distributed parity.
7. RAID 6 - Block-level striping with double distributed parity.
Out of these RAID types 0, 1, and 5 and their combinations are most often implemented in industries.
Let see how to implement these types in Linux environment.
Package used to implement RAID in Linux is mdadm
mdadm -C <RAID device name> -l <RAID level> -n <No of disk partitions> <partitons>
RAID 0
mdadm –C /dev/md0 –l 0 –n 1 /dev/sda
RAID 1
mdadm –C /dev/md1 –l 1 –n 2 /dev/sd{a,b}
RAID 5
mdadm –C /dev/md5 –l 5 –n 3 /dev/sda{5,6,7} –x 1 /dev/sda8
Once the RAID create command is issued the percentage of creating of RAID can be viewed using the below command
watch cat /proc/mdstat
#To display the details of RAID partition
mdadm –detail /dev/md1
#To scan disks in RAID
mdadm –-assemble –-scan
#To identify faulty disk
mdadm –f /dev/md1 /dev/sda
#To remove RAID partition
mdadm –r /dev/md1
mdadm –S /dev/md1
No comments:
Post a Comment