Server installation linux system tutorial

1. Burning of Linux image

1. First open any browser on the computer (IE, Microsoft Edge, chrome, Firefox), enter the URL    https://www.centos.org/,  we can see the following interface, choose to get centos immediately to download the latest installation mirror, copy and download Link ( http://isoredirect.centos.org/centos/7/isos/x86_64/CentOS-7-x86_64-DVD-1810.iso ) to open Xunlei, wait for a quarter of an hour (waiting time is determined by personal actual internet speed).

 

 

2. Download the dedicated Linux image burning tool address: https://www.pendrivelinux.com/

After completion, double-click the executable file just downloaded, the interface shown in the figure below appears

Choose I agree, enter the following interface, the current server basically supports UEFI boot, but there may be unsupported situations, so we choose cnetos installer when choosing mirror recording, here we need to pay attention to buying a better U The disk will copy the centos image to the U disk when burning, and the size of the image is 4GB+, so the file system of the U disk needs to be on the place indicated by the arrow in the NTFS format.

When you are ready, click create. I am using a usb3.0 U disk, so I basically wait for 5 minutes to complete. As shown in the figure below, so far we have completed the burning of the image! !

 

 

 

Second, the installation of the system

1. Our demonstration environment is a dell server, boot into the system initialization interface, press F11 to enter the startup management as shown below:

As shown in the figure below, we entered the Dell boot manager to set the boot mode to bios. As shown in the red box in the figure, different types of servers may have different setting methods, but just remember two points. The first boot manager is booting. When the keyboard chooses which button is optimistic, the second boot mode (boot mode) is set to bios.

Then select the booted hard disk as the inserted U disk, here I use the U disk of SanDisk, and you can see that it is sandisk (SanDisk) in the picture. After selecting the ↓ key, press the enter key to boot from the U disk.

Now you can enter the installation interface of centos, here is not too much introduction, see the screenshot

The expected capacity is changed to 100GB here, as shown below

The / partition is the system partition to carry system files. Here we generally configure it as 100GB. The /boot partition is the system boot partition. Here we configure it as 1GB. Swap is the swap partition. Here we configure it as twice the physical memory (if the server is plugged in with an 8G Memory stick, here we configure it as 16Gb), so far the system partition is completed. Then start the installation of the system. Here we set the root password, which can be changed to 123456 afterwards. After setting it, it will be a long wait.

At this point, the installation is complete and you can restart.

 

2. Configure ip

Boot into the system and enter the user name and password, and then enter the interface shown in the figure and enter the command as shown in the figure below. My virtual machine environment, if it is a real machine, enter the system network configuration directory, you will see ifcfg-ens1, ifcfg-ens2 , Ifcfg-ens3, ifcfg-ens4, we need to configure the first network port of the server, so edit ifcfg-ens1

Configure IP, MASK, GATEWAY, DNS according to the actual situation of the root play. If you don't know how to configure it, you can Baidu by yourself. Let me explain again:

TYPE=Ethernet
BOOTPROTO=dhcp
DEFROUTE=yes
PEERDNS=yes
PEERROUTES=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=yes
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_PEERDNS=yes
IPV6_PEERROUTES=yes
IPV6_FAILURE_FATAL=no
NAME=eno16777736
UUID=ae05ccde-6a29-4332-b486-f3042da73ac0
DEVICE=eno16777736
ONBOOT=no

Here are the locations that need to be modified:

#修改
BOOTPROTO=static #这里讲dhcp换成ststic
ONBOOT=yes #将no换成yes
#新增
IPADDR=192.168.85.100 #静态IP
GATEWAY=192.168.85.2 #默认网关
NETMASK=255.255.255.0 #子网掩码

After saving and exiting, restart the network service:

# service network restart
Restarting network (via systemctl):                        [  确定  ]

View current ip:

# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: eno16777736: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:0c:29:e7:b8:77 brd ff:ff:ff:ff:ff:ff
    inet 192.168.85.100/24 brd 192.168.85.255 scope global eno16777736
       valid_lft forever preferred_lft forever
    inet6 fe80::20c:29ff:fee7:b877/64 scope link 
       valid_lft forever preferred_lft forever
3: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN 
    link/ether 52:54:00:b9:8f:6c brd ff:ff:ff:ff:ff:ff
    inet 192.168.122.1/24 brd 192.168.122.255 scope global virbr0
       valid_lft forever preferred_lft forever
4: virbr0-nic: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast master virbr0 state DOWN qlen 500
    link/ether 52:54:00:b9:8f:6c brd ff:ff:ff:ff:ff:ff

After the configuration is complete, test whether ping baidu.com can accept the return packet. If so, the basic configuration of the server has been completed and can be put on the shelf.

Guess you like

Origin blog.csdn.net/qq_15057857/article/details/89841590