Install the entire Linux operating system on the soft RAID Partition

Source: Internet
Author: User

I. Introduction to raid

What is raid? What is it? If you don't understand it, go to Baidu. Here we will only introduce Soft Raid. Soft Raid is a raid implemented by software. The advantage is that a general PC can build a disk array at a low cost. Of course, the performance is much worse. Hardware raid is implemented through raid cards (array cards), which provide good performance but high prices. Software raid and hardware raid have their own advantages. They are mainly used based on actual conditions. Currently, the price of hardware raid is not expensive. We recommend that you purchase hardware raid when you have high performance requirements.

Ii. demonstrate how to install the entire Linux operating system to a soft RAID so that even if a disk breaks down, the normal operation of the entire system will not be affected.

1. As with the normal installation of the Linux system, the key is to pay attention to the disk partition.

2. Click the next step to see that the system recognizes two hard disks of the same size. We will make these two disks into RAID 1 to install the operating system.

3. Because the software raid is created on the disk partition, you must first partition the disk. The two disks must have the same partitions. Before partitioning, make sure to plan the number of partitions? How big is each distinction? Which directory is mounted? Plan based on your own needs.

Note: After completing raid, you cannot partition the raid disk. This is different from hardware raid.

Click "new". For example, a m partition is allocated to the hda hard disk to mount/boot partitions.

4. Allocate a m partition for the HDB disk to mount the/boot partition.

5. Create a m partition for the hda hard disk to mount swap.

6. Create a m partition for the HDB hard disk to mount swap.

7. Use all the remaining hda space as a partition to mount /.

8. Just like above, HDB is operated.

9. Click the raid button, select the second item, and click OK.

10. Select one by one. Here we are doing raid1 and check hda3 and HDB3.

11. Select


12,

13. After the operation is complete, the entire partition structure is shown in

14. After the system is installed, a prompt is displayed, such as the interface. At this time, do not restart, because the two hard disks are performing raid initialization, wait until the initialization is complete, restart too early will cause the system to fail to start.

15. You can enter the character terminal through CTRL + ALT + F3 to check whether the initialization is complete. Enter the command CAT/proc/mdstat

As shown in, it indicates that the system has been completed and can be restarted. If a progress bar is still running on the interface, the system cannot be restarted.

3. Although we have installed the system on raid1, the primary Boot Record is actually only on the hda disk. If the hda disk is broken, the HDB disk cannot boot the system. The next task is to install the grub boot program on the HDB disk. No matter which disk is broken, the normal startup and running of the system will not be affected.

1. Run the grub Program

2. Find the partition where/boot is located. For example, all partitions are installed on the first partition of the first hard disk.

Note: You must enter the complete path when entering the find command to search. The Tab key cannot be supplemented. If/boot is not mounted under a separate partition during system installation, the path will change to find/boot/GRUB/stage1, if/boot is mounted under a separate partition, It is find/GRUB/stage1.

3. Write the grub boot program to the HDB of the second disk.

After the operation is completed, the restart and operation of the system will not be affected no matter which hard drive is hda or HDB.

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.