As we operation and maintenance learners, usually use Linux, but will use Windows, so the installation of Linux and Windows dual system on a computer has become a just need, so how to install Windows and Linux dual system

Experimental environment

Computer: laboratory desktop

Flash drive: Kingston DT106

Installation package: Win7.gho rHEL7.5

Software: General PE toolbox (Windows installation tool), PowerISO (Linux installation tool), DiskGenius (hard disk tool)

Install Windows

①**** Make Windows installation tool ****

First of all, install a software called general PE on Windows, installed PE on the market even very, what cabbage, old peach, Dr. Han and so on, I have used, but still feel that the general PE toolbox is better (not soft text), the page is more concise, and the function of a lot.

General PE toolbox software official website www.tongyongpe.com/

Once installed, the interface looks like this

Insert the USB flash drive (please back up the usb flash drive if it is important)

As shown above, check NTFS and click one button to make usb flash drive boot disk. The progress bar is finished and the USB flash drive boot disk is ready

② Install Windows

First enter the BIOS mode of the installed computer, then locate the Boot option, set boot Mode to Legacy, and set the usb drive to the first boot drive

Then save and restart

After the restart, the usb flash drive installation screen of general PE is displayed. Select the first one as shown in the following figure

After entering the PE interface, select DiskGenius

Select delete all existing partitions

The entire hard drive is then divided into three partitions using fast partitioning

Delete the last partition to install Linux (100GB is enough), and then rebuild the MBR. Be sure to do this

Close the software, use general PE one key quick installation, I installed here is Win7

Click Start, wait for the progress bar to run out, and then restart your computer to see that Windows is installed

At this point, Windows is installed

(3) Check the system driver and fill the gaps

Here you can use the driver Sprite to detect the driver

As shown above, Windows 7 is considered ready to use as long as no driver is not installed

Install Linux

① Make Linux installation tools

After this step, the USB disk will be formatted.

Start by installing Poweriso on Windows, the software interface is as follows

Click Tools and click Make Bootable USB drive

Then select the corresponding mirror and flash drive and click Start

Once you have successfully used a Linux or Windows installation usb drive, plug it in again and the display capacity and name will change

② Install the Linux operating system

Because the BIOS Settings have been modified before, it will automatically enter the USB boot, that is, the interface for installing Linux, select the first one

Ps: The picture here is the picture I simulated in the virtual machine. I did the same operation in the real host. The reason why I used virtual machine simulation is that this screenshot is convenient

Then wait for a moment, the installation interface will enter, select English and click Continue

An installation options screen is displayed

As shown in the figure above, the time zone is Shanghai, Asia, the keyboard is American, the language is English, the installation source is local, and the installation software is Server with GUI. What needs to be paid attention to is the installation location

To set it to look like the following, make sure you select the same hard drive you left out in Part 1, and then select: I will configure Partitioning

Then set the boot partition to 200m, the swap partition to the computer memory size, and the remaining space to /

Then click Continue, you will enter the following interface, create root password and user, you can start the installation, wait until the progress bar is finished, the system is regarded as a successful installation

Modify the GRUB file

When you restart the computer, you will find that the system automatically enters the Linux interface, but Windows is not available. Don’t worry, Windows is still available, so GRUB must have overwritten the original Windows boot, so GRUB is used to boot multiple systems. On the other hand, the Windows master boot record overwrites the GRUB boot of Linux, so Linux does not boot properly and only boots Windows, so you need to manually modify the GRUB file

Log in to Linux, open the terminal, and switch to the root user

vim /boot/grub2/grub.cfg                Add the following on line ##87



menuentry 'mirsoft windows7'{



set root='hd0,msdos1'                   Hd0 = hd0 = hd0 = hd0 = hd0



chainloader +1                          ##msdos1 indicates the first partition of the hard disk



}
Copy the code

Then restart the system and you will find the option of Windows 7