Comprehensive Analysis of Linux disk array Configuration

Source: Internet
Author: User

The Linux disk array is used to protect system data. Here we will start with the disk array, and then detail how to configure the Linux disk array on the Linux system. I believe that after reading this article, you will certainly have a lot of GAINS. I hope this article will teach you more things.

Disk Array configuration: Role: Prevent data loss
RAID: Redundant Array:
Save multiple copies of data simultaneously: image:
Saves only one copy of the data), saves some additional information, and uses this information to restore the source data.
RAID1: Image volume
RAID5: Strip volume with parity check information
RAID1: 2 disks with 50% Utilization
RAID5 requires at least 3 disks, disk utilization N-1)/N

It is best to use the same specification as the hard disk in the disk array, and the capacity should be the same

The tool used is MDADM.
The role of the mdadm. conf file: controls that a configured RAID device can be automatically generated when the system starts.
Echo "DEVICE/dev/hd * [0-9]/dev/sd * [0-9]">/etc/mdadm. conf
Mdadm -- detail -- scan>/etc/mdadm. conf

Partition: FDISK/DEV/SDG

Create RAID:

Mdadm -- create/dev/md0 -- level = 1 -- raid-devices = 2/dev/sdg [56]
View RAID status: cat/proc/mdstat

Format the RAID device: MKFS-T EXT3/DEV/MD0
Create directory: MKDIR-P/DISK/MD0

Load: MOUTN/DEV/MD0/DISK/MD0

Run the command to generate the MDADM. CONF file.

The configuration of the Linux disk array is completed here. There may be some problems. Let's also say:
Configure Automatic loading upon startup, making it difficult to restart

Vi w. c

 
 
  1. #include "stdio.h"  
  2. main()  
  3. {  
  4.     printf("hehe\n");  

Compile command: gcc-o w. o w. c
Yast2

  1. Introduction to the method for determining Linux blacklist
  2. Add hard disks for Linux in virtual machines
  3. Solve Linux root password retrieval
  4. 10 new Linux knowledge points
  5. Detailed introduction to the use of Linux redirection

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.