歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> Linux教程 >> CentOS網絡啟動錯誤

CentOS網絡啟動錯誤

日期:2017/2/28 14:29:35   编辑:Linux教程

我所使用的是CentOS虛擬機,在那個環境下有dhcp服務,本來用的好好的,可是突然出現了如下錯誤:

錯誤:determining IP information for eth0 ... failed; no link present . Check cable?

開始還以為是網線掉了,結果好的。

後來去網上百度,Google了一下,結果出現的都是

Getting a DHCP Address in a Red Hat Linux 9.0 Virtual Machine
When a Red Hat Linux 9.0 guest operating system tries to get a DHCP address, the attempt may fail with an error message that states the link is down. On ESX Server, this happens only if you are using the vlance driver for your network connection.
To work around this problem, become root (su -) and use a text editor to edit the following files in the guest operating system. If only one of these files exist, make the change for that file only.
/etc/sysconfig/network-scripts/ifcfg-eth[n]
/etc/sysconfig/networking/devices/ifcfg-eth[n]
In both cases, [n] is the number of the Ethernet adapter — for example, eth0.
Add the following section to each of these two files:
check_link_down () {
return 1;
}

Then run the command ifup eth[n] (where [n] is the number of the Ethernet adapter) or restart the guest operating system.

結果我試了一下還是不行,就是出錯改變了變成了如下錯誤

determining IP information for eth0 ... failed;

後來想了一下修改ifcfg-eth0,把原來的dhcp改為static,整個配置改成靜態的,然後再重啟網絡,就發現可以了。

在CentOS 7上利用systemctl添加自定義系統服務 http://www.linuxidc.com/linux/2014-07/104487.htm

CentOS 7.0下編譯安裝LNMP http://www.linuxidc.com/Linux/2014-07/104247.htm

CentOS 7.0體驗與之前版本的不同 http://www.linuxidc.com/Linux/2014-07/104196.htm

CentOS 7 正式版發布下載 http://www.linuxidc.com/Linux/2014-07/104146.htm

U盤安裝64位CentOS 6.5方法 http://www.linuxidc.com/Linux/2014-04/100035.htm

Win7安裝64位CentOS 6.4雙系統詳細圖文教程 http://www.linuxidc.com/Linux/2014-04/100032.htm

CentOS與Windows雙系統安裝注意事項記錄 http://www.linuxidc.com/Linux/2014-05/101571.htm

UEFI+GPT安裝Windows8和CentOS雙系統 http://www.linuxidc.com/Linux/2014-05/101575.htm

更多CentOS相關信息見CentOS 專題頁面 http://www.linuxidc.com/topicnews.aspx?tid=14

Copyright © Linux教程網 All Rights Reserved