Install Multiple linux systems on one server

Source: Internet
Author: User

If multiple linux systems are installed on one server as NIC drivers in the company, you must test the driver on Multiple kernel versions. There is only one server. In this case, there are only two solutions. The first solution is to have one system with multiple kernels, and the second solution is to install multiple systems, due to the inconsistent linux versions of the company's servers and concerns about problems, we chose to install multiple systems. The general process is as follows. First, use a CD to install a system, and specify the space for the first system during partitioning. Because the hard disk is too small, it is only 150 GB and you want to install three systems, therefore, only 50 GB is allocated. It is equivalent to GB free space left, no partitions, no formatting. Use a CD to first install the first system. The second and third systems can be installed directly on the hard disk because there is already one system. (If there is a CD, you can continue using the CD directly.) 1. The partition first enters the first system and divides the remaining 100 GB into two 50 GB primary partitions. The specific method is as follows: first execute fdisk-l and you will see/dev/sda. If there are multiple hard disks, there may be sdb, sdc, etc, here I will show that there is sda1 (root partition of the existing system), sda2 (SWAP partition) and then execute fdisk/dev/sda. This is the prompt that you can enter m to see. Input n indicates to create a new partition and input p, because the installation system requires the primary partition because the primary Partition number 1 and 2 have been occupied by the root partition and swap partition of the first system, therefore, only 3 and 4 can be used here. 3 represents the third primary partition and press enter directly, indicating that the default address is used as the start address of the new partition. Enter the partition size. Here you can enter the number of cylinders or the size directly. I will enter the number of cylinders directly here, because the number of cylinders occupied by the first partition is about 6300, it is about 50 GB + 6300 input w. Save the partition and you will get/dev/sda3. Create/dev/sda4 in the same way. Next, run partprobe/dev/sda to update mksf. ext3/dev/sda3 format the new primary partition/dev/sda3 to ext3. If the partition fails, restart mksf first. ext3/dev/sda4 format the new primary partition/dev/sda4 to ext3 and mount/dev/sda3, do not be unable to operate on it 2. Preparations before installation (you need to download the iso image file of the corresponding version in advance, this article uses CentOS_6.3_Final.iso as an example) the above mentioned need to be mounted on/dev/sda3, mount it to mkdir/sda3 mount/dev/sda3/sda3 under/sda3. Cd/sda3 copy CentOS_6.3_Final.iso to/sda3. here we need to extract the two folders (isolinux and images) in iso from mkdir a mount-o loop CentOS_6.3_Final.iso a cp-r a/isolinux. cp-r a/images. modify/boot/grub. add the following category in conf: title install CentOS6.3 root (hd0, 2) # hd0 indicates the first disk, 2 indicates/dev/sda3, this is because the kernel/isolinux/vmlinuz initrd/isolinux/initrd is added starting from 0. img 3. Restart the machine. When you enter the system, select install CentOS6.3. On the installation page, select/dev/sda3 to find instal. L. after img is installed and enters the new operating system, grub needs to be updated. conf. Otherwise, you can only access the new system. The specific operations are as follows: mkdir/sda1 mount/dev/sda1/sda1 cd/sda1/boot/grub vi grub. conf copies the startup parameters of the first system from the title line to the initrd line (not the installed title we added) then add it to the grub of the current system. conf. After restarting, you can see that there are two System Options. The third system method is similar.

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.