How to configure IP address in linux7

How to configure
linux7 IP address author:WYF
First enter
vi /ect/sysconf ig/network-scripts/ifcfg-enp7s0f0** from the command line (this is the first port, and the second port is ensp7s0f1 for the same reason), as shown in the figure below
eth insert picture description here
ethx It is the number of network port ensp7s0fx and also the number of network port x represents the number. The
second step is "i" to enter the editing.
Set bootproto to static ip
, namely: bootproto=ststic

Set ONBOOT to yes to indicate whether to activate the network card when the system is started,
ie: ONBOOT=yes
Step 3 Configure IP address, subnet mask, gateway domain name
IPADDR=(IP address)
NETMASK=(subnet mask)
GATEWAY=(gateway) )
DNS1= (domain name)
PREFIX= (prefix digits)
Step 4 Press "Esc" to exit, and enter "wq" in the exit editing state and press Enter to save the current configuration

Guess you like

Origin blog.csdn.net/m0_52425873/article/details/112862599