Original: https://www.jianshu.com/p/ce08cdbc4ddb?utm_source=tuicool&utm_medium=referral
This article mainly introduces the ultra-detailed process of VMware installation Centos7 (graphics), which has certain reference value. Interested friends can refer to it
1. Software and hardware preparation
Software: VMwear is recommended, I use VMwear 12
Mirror: CentOS7, if there is no mirror, you can download it from the official website: http://isoredirect.centos.org/centos/7/isos/x86_64/CentOS-7-x86_64-DVD-1804.iso
Hardware: Because the virtualization software is installed on the host to install centos, there are certain requirements for the configuration of the host. At least I5CPU dual-core, hard disk 500G, memory 4G or more.
2. Virtual machine preparation
1. Open VMwear and select a new virtual machine
2. Typical installation and custom installation
Typical installation: VMwear will apply the mainstream configuration to the operating system of the virtual machine, which is very friendly for novices.
Custom installation: Custom installation can strengthen some resources and remove unnecessary resources. Avoid wasting resources.
Here I choose custom installation.
3. Virtual machine compatibility selection
Pay attention to compatibility here. If the virtual machine created by VMwear12 is copied to VM11, 10 or lower versions, there will be an incompatibility. If the virtual machine created with VMwear10 is opened in VMwear12, there will be no compatibility issues.
4. Choose to install the operating system later
5. Selection of operating system
Here, select the operating system to be installed later. The correct choice will make vm tools more compatible. Here choose CentOS under linux
6. Virtual machine location and naming
The virtual machine name is a name, which is convenient for you to find when there are many virtual machines.
The default location of VMwear is under the C drive, I changed it to the F drive here.
7. Processor and memory allocation
Processor allocation should be allocated according to your actual needs. If the CPU is not enough during use, it can be increased. This time, we will only install CentOS demo, so choose 1 for both processor and core.
Memory is also allocated according to actual needs. My host machine memory is 8G so I allocate 2G memory to the virtual machine.
8. Choose the type of network connection. There are four types of network connection: bridge, NAT, host only and no network connection.
Bridge: If the bridge mode is selected, the virtual machine and the host machine are in the same level relationship on the network, which is equivalent to being connected to the same switch.
NAT: The NAT mode means that the virtual machine must first pass through the host to communicate with the outside world if it is to be connected to the Internet.
Host only: The virtual machine is directly connected to the host
Bridge and NAT mode to access the Internet process, as shown in the figure below
Difference between bridging and NAT
Select bridge mode here
9. The remaining two items can be selected according to the default options of the virtual machine
10. Disk capacity
Temporarily allocate 100G of disk capacity, which can be increased at any time later. Do not check Allocate all disks immediately, otherwise the virtual machine will directly allocate 100G to CentOS, which will reduce the remaining hard disk capacity of the host.
Check the option to split the virtual disk into multiple files, so that the virtual machine can be easily copied and copied with the storage device.
11. Disk name, the default is fine
12. Cancel unneeded hardware
Click on Customize Hardware
Select unwanted hardware such as sound cards, printers, etc. and remove them.
13. Click Finish, the virtual machine has been created.
3. Install CentOS
1. Connect the disc
Right click on the virtual machine you just created and select Settings
First select CD/DVD, then select to use the ISO image file, and finally select Browse to find the downloaded image file. Connect at startup must be checked and confirmed.
2. Turn on the virtual machine
3. Install the operating system
After starting the virtual machine, the following interface will appear
- Install CentOS 7 Install CentOS 7
- Test this media & install CentOS 7 Test the installation file and install CentOS 7
- Troubleshooting to fix failures
Select the first item, install CentOS 7 directly, press Enter, and enter the following interface
Select the language used during the installation process, here select English, keyboard select the American keyboard. Click Continue
first set the time
Select Shanghai as the time zone and check whether the time is correct. Then click Done
Select the software to install
Select Server with Gui and click Done
Select the installation location, where disk partitioning can be performed.
Select i wil configure partitioning (I will configure the partition), then click done
As shown in the figure below, click the plus sign, select /boot, and assign 200M to the boot partition. Finally click Add
Then allocate space to the other three areas in the same way and click Done
Then a summary message will pop up, click AcceptChanges (accept changes)
Set the hostname and network card information
First of all, you need to open the network card, and then check whether you can get the IP address (I am a bridge here), and then click Done after changing the host name.
Finally select Begin Installation (start installation)
set root password
After setting the root password, click Done
Click USER CREATION to create an administrator user
After entering the username and password, click Done
Wait until the system is installed and restart the system
The above is the whole content of this article, I hope it will be helpful to everyone's study.
The following is my own method of cloning a virtual machine and setting a fixed IP, record it in case you forget:
Bridge Mode Network Configuration
1. Configure the ip address and other information in the /etc/sysconfig/network-scripts/ifcfg-ens33 file as follows:
Order:
vi /etc/sysconfig/network-scripts/ifcfg-ens33
Modify as follows:
YPE="Ethernet" # 网络类型为以太网
BOOTPROTO="static" # 手动分配ip
NAME="ens33" # 网卡设备名,设备名一定要跟文件名一致
DEVICE="ens33" # 网卡设备名,设备名一定要跟文件名一致
ONBOOT="yes" # 该网卡是否随网络服务启动
IPADDR="192.168.220.101" # 该网卡ip地址就是你要配置的固定IP
GATEWAY="192.168.220.2" # 网关
NETMASK="255.255.255.0" # 子网掩码
DNS1="8.8.8.8" # DNS,8.8.8.8为Google提供的免费DNS服务器的IP地址
2. Configure network work
Add the following configuration in the /etc/sysconfig/network file
命令:
vi /etc/sysconfig/network
修改:
NETWORKING=yes # 网络是否工作,此处一定不能为no
3. Configure public DNS service (optional)
Add the following configuration in the /etc/resolv.conf file
nameserver 8.8.8.8
4. Turn off the firewall
systemctl stop firewalld # 临时关闭防火墙
systemctl disable firewalld # 禁止开机启动
5. Restart the network service
service network restart
Here is the cloned virtual machine:
First check the gateway of the virtual machine
2. Shut down the virtual machine to be cloned, right-click the virtual machine to be cloned:
Right-click on the virtual machine, select "Manage", "Clone"
then the next step
next step
Select the second "Create a full clone", then the next step
Name your clone machine, select a location, and click "Finish".
Then start cloning, the time will not be too long, the whole process is about 1~2 minutes.
After the cloning is completed, click Close to indicate that the cloning is successful. At this point, you can see the newly cloned virtual machine "Clone" in the virtual machine list. as follows:
At this time, the configuration of the cloned virtual machine is the same as that of the original virtual machine. Next, we need to configure the network, host name, etc. Modify the IPADDR in
the configuration file /etc/sysconfig/network-scripts/ifcfg-ens33
IPADDR="192.168.220.102"
Modify the hostname:
hostnamectl set-hostname xxxx(你要的主机名字)
Modify the hosts file to associate the name with the IP
After entering the command "vi /etc/hosts", add it to the configuration file
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.220.103(你所修改的主机IP) xxxxxxxx(你要的主机名字)
reboot: reboot