Blogger Information
Blog 61
fans 1
comment 0
visits 69734
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
0723-centos设置网络访问
我的博客
Original
1237 people have browsed it

1、使用命令ip addr查询本地网卡和IP

2、使用命令 cd /etc/sysconfig/network-scripts/ 进入网卡配置目录

3、使用命令 vi ifcfg-ens32打开网卡配置文件(用ipconfig查询网卡地址,假设查询到的本地网卡维ens32)

4、按insert或者i键进行插入文本:GATEWAY=192.168.88.1

IPADDR=192.168.88.128

NETMASK=255.255.255.0

DNS1=114.114.114.114

DNS2=8.8.8.8

ARPCHECK=no

5、修改BOOTPROTO=dhcp改成static静态IP,修改ONBOOT=no改为yes, 开机启动

6、service network restart  重启网络

1.png

Correction status:qualified

Teacher's comments:继续努力
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post