Server hardware and RAID configuration

Playing with server hardware and RAID configuration
RAID disk Array Introduction TO RAID 0 Disk Array Introduction to RAID 5 Disk Array Introduction to RAID 6 Disk Array Introduction to RAID 1+0 Disk Array Introduction to the disk array experiment

An introduction to RAID disk arrays
1, it is an abbreviated Independent Redundant disk Array
; 2, it combines several Independent physical hard Disks in a variety of ways to form a disk group (logical hard disk). To provide higher than a single hard disk storage performance and provide the data backup technology
3, known as the way of disk array of different RAID Levels (RAID Levels) commonly used RAID level

RAID 0, RAID 1, RAID5, RAID 6, RAID 1 + 0, etc
An introduction to RAID 0 disk arrays
1 continuous segmentation data bits or bytes as a unit, parallel read/write on multiple disks, so has the very high data rate, but it has no data redundancy
2, RAID 0 is just simply increase performance, did not provide guarantee for the reliability of data, and one of the disk failure will affect all data
3, RAID 0 cannot be applied to data security demanding situations
An introduction to RAID 1 disk arrays
RAID 1 (2)
1, through the disk image data to realize data redundancy, each other in pairs of independent disk backup data
2, when the original data is busy, can be directly read data from the mirror copy, so the RAID 1 can improve read performance
3, RAID 1 is the cost per unit of the highest in the disk array, but provides high data security and usability. When a disk fails, the system can automatically switch to read and write on the mirror disk instead of reorganizing the failed data
An introduction to RAID 5 disk arrays
1, N (N> = 3) piece of disk array, a data N – 1 stripe, 1 and check the data at the same time, a total of N copies of data on the N drive cycle balance store
2, N piece of disk read and write at the same time, the read performance is very high, but due to problems have check mechanism, write performance is relatively high,
3, (N – 1)/N
4 disk utilization, high reliability, allow bad 1 piece of plate, do not affect all the data
An introduction to RAID 6 disk arrays
N. = 4) piece of disk array, (N – 2)/N disk utilization
compared with RAID 5, RAID 6 added a second independent parity information block
two independent parity system using different algorithms, even though the disk failure will not affect the use of the data at the same time
relative to RAID 5 more “loss”, so write performance is poorer
Introduction to RAID 1+0 disk arrays
RAID 1+0
N (even, N> =4) after two mirror blocks, then combined into a RAID 0
N/2 disk utilization
N/2 block read and write at the same time, N block disk read
performance is high, high reliability
Disk array experiment

1、Find the process number: fuser /data
(process number)
2. kill process: kill-9 (process number) 
3、Uninstall: sumount /data
Check raid: mdama-Dsv.
4, Create raid5: mdadm -C md0 -l 5 -n 3 -x 1 /dev/sd/[b-e]
Check raid status information: mdadm -D /dev/mad/md0
5、Generate raid configuration file: madadm -Dsv > /etc/mdadm.conf
Formatted: mkfs.ext4 /dev/md/md0
6, create mount point: mkdir -pv/data
7. Permanent RAID mount
(1) Get the UUID of the RAID.
mdadm --detail /dev/md/md0 | grep -i uuid
(2) Start setting up mdadm.conf.
vim /etc/mdadm.conf
ARRAY /dev/md0 UUID=.......
(3) Get test information
blkid /dev/md0(this uuid is the global uuid, used to uniquely represent this device)
(4) Set boot-up
vi /etc/fstab
UUID=....... /data ext4 defaults 0 0
(5) Let the /etc/fstab configuration take effect.
mount -a
(6) Testing
df -Th

Read More: