Environment preparation and Linux installation

    "If you want to do a good job, you must first sharpen your tools." This article will fully demonstrate the installation and configuration process of the entire development environment, so as to prepare the foundation for subsequent development and experiments. If you have already installed the environment, you can skip this article directly; if you are using Linux for the first time, it is recommended to follow the steps in this article.


1. Environment and software preparation

    Hardware conditions: ordinary computer will do

    Software preparation: VMware Workstation Pro15.5.0, Centos 7.0

    ps: If your computer is now installed with the linux operating system itself, and only operates on a stand-alone machine, you don't need to install VMware, or even continue to read this article. If your computer is installed with windows operating system, then this article is tailor-made for you.

1.1. About PC configuration

    The memory is recommended to be greater than 4G, and the CPU needs to support VT virtualization technology (required when installing Centos in a VMware virtual machine, which will be mentioned below). Unless it is an old computer many years ago, the current market standard is fully satisfied.


1.2 VMware virtual machine software

 VMware is an advanced desktop computer virtualization software that can run multiple different operating systems simultaneously on the same pc. The purpose of using her is to easily install and experience different operating systems on the same pc, or to simulate the effect of multiple computers, so that you don't have to spend money to buy multiple computers.

 ps: VMware is a paid software, if you use it for learning, you can use the trial version.


1.3 Centos operating system

 The main distribution versions of the linux operating system are: RedHat, Centos, Ubuntu, etc. This article uses Centos7.0, please refer to the official website for the difference between different versions.


 This article uses win10 operating system 64-bit, VMware uses 15.5.0, and CentOs uses 7.0. It is strongly recommended that the following operations are the same as in this environment, because different software versions have slightly different installation procedures and different operation commands (for example, there are many differences between CentOs6 and CentOs7 commands). Of course, it is also possible to use other different versions together, just pay attention to the difference and draw inferences from one case.


2. VMware installation

2.1 Installation

 The installation process is very simple, you can just click next in a fool's way. Select based on individual needs only if individual steps need to be customized.


 After downloading and decompressing, double-click the installation package

 Click the Next button


  Check license terms


 Change the installation directory (the default is to install on the c drive, it is recommended to modify it to another directory with large disk space)


 In the pop-up new window, after selecting or creating a new directory, click the OK button


 Click the Next button


 Uncheck the default (both are selected by default, according to personal preference)


 Create Shortcut


 Click to install


 start installation


 The installation is complete

 Click Finish to use for 30 days



2.2 Running VMware

 Click the desktop shortcut icon to start, so easy!


 ps: At this point, the VMware virtual machine installation is complete, and the CentOs operating system will be installed in this virtual machine later.


3. Centos installation

 After installing the VMware virtual machine software, you can simulate the system hardware resources, and then install the CentOs operating system.

 ps: You can understand that the process of hardware resource simulation is the process of purchasing computer hardware, and you can install the operating system only with the computer. This also just reflects the power of VMware, so that you don't have to buy a physical computer to install the CentOs operating system.


3.1 Hardware resource simulation

 Open the VMware virtual machine software and click the "Create a new virtual machine" button


Select "Typical" and click "Next"


Keep the default "Install the operating system later" and click "Next"


Select the operating system type and version, this article selects centos7


After naming the virtual machine and setting the storage location, click Next


Specify the disk size (the default size is 20G, you can use the default) and click Next


Click the Customize Hardware button


Adjust the memory size to 2G (according to your computer configuration)


According to the physical computer configuration, adjust the number of CPUs and cores, and enable the virtualization function


Set the CD-ROM to use the iso image file you just downloaded


Set the network mode to "NAT mode"


Others do not need to be configured, click the "Close button" to return to the "New Virtual Machine Wizard"


Click the "Finish" button,

 When this image appears, your virtual machine has been successfully configured. The next step is to actually install the CentOs operating system.


3.2 CentOs installation

3.2.1 Start the virtual machine and enter the system installation

 Click the "Power On This Virtual Machine" button


 ps: This step may give an error: "This virtual machine has been configured to use a 64-bit guest operating system. However, 64-bit operations cannot be performed", prompting "This host is up to Interl VT-x, but Interl VT-x is in Disabled state".

 Reason: The computer does not support VT virtualization technology or the computer supports it but is not turned on. As long as the computer is not too old, it is generally supported. You can restart the PC and enter the BIOS to enable virtualization support. It should be noted that different brands or models of motherboards may have slightly different BIOS settings.


Select the installation system "Install CentOS 7"

 Enter the virtual machine: click the mouse or ctrl+g, move the mouse out of the virtual machine: ctrl+alt. Use the up and down arrows to select within the virtual machine.


The system will automatically install, and you will enter the welcome interface later.


Select language as English


3.2.2 Time and time zone settings




3.2.3 Language setting

 Language selection adds Chinese support to avoid garbled characters




3.2.4 Installing the group package



3.2.5 Partition Settings





3.2.6 Hostname and Network Settings




 ps: Choose to manually configure the IP to avoid getting the IP automatically every time it will become a problem. So how to set the IP address and gateway? By clicking the "Edit" menu of the virtual machine, the virtual network editor will pop up, view the network named "VMnet8", and view the "NAT settings" to view the gateway. Fill in the gateway and IP here only need to be in the same network segment. That's it.



After the setup is complete, turn on the network and click the Done button


3.2.7 Officially enter the installation and set the account password

 Click the Start Installation button


set root password


ps: If the set password is too simple, Weak will be prompted, and you need to click the Done button twice.


Set up a regular account


 After that, make a cup of coffee and quietly wait for the automatic installation of the system to complete. It takes about 10-20 minutes depending on the configuration of the physical machine. After the installation is complete, restart the system.



3.2.8 Configuration after installation

 After clicking Reboot in the above picture, the system will restart automatically. After the startup is completed, it will automatically enter the following interface


agree to license


Click the Finish Configuration button

The system will restart automatically again, and the login interface will appear after the restart is successful.

3.2.9 Login to the system

Log in with the previously set root account password


After successful login, keep the default settings, and click Next to complete the initial settings