centos6.5安装完成后,默认是没有开启网卡的,需要我们手工开启网卡才能访问网络。

安装完成后,打开终端输入ping www.baidu.com,提示不认识的主机。

centos6.5网络配置

输入ifconfig命令查看网卡状态,发现网卡没有分配ip地址,是不可用的。

centos6.5网络配置

接下来我们要将网卡设置为开机启动。

首先先确保具有root权限

这里我们输入 su root切换到root用户。

centos6.5网络配置

输入 vi /etc/sysconfig/network-scripts/ifcfg-eth0对网卡进行设置。

centos6.5网络配置

将ONBOOT修改为yes

centos6.5网络配置

centos6.5网络配置

保存。

重启网络服务。

service network restart

centos6.5网络配置

现在我们可以发现已经可以上网了。

centos6.5网络配置

centos6.5网络配置

 

 

 

相关文章:

  • 2022-01-05
  • 2022-12-23
  • 2022-12-23
  • 2021-10-23
  • 2021-04-01
  • 2022-12-23
  • 2021-07-10
  • 2021-09-12
猜你喜欢
  • 2022-02-15
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-12
  • 2021-12-05
相关资源
相似解决方案