redhat7.0修改網卡名字爲eth0

#vim /etc/sysconfig/grub
GRUB_CMDLINE_LINUX="rd.lvm.lv=rhel/root crashkernel=auto  rd.lvm.lv=rhel/swap vconsole.font=latarcyrheb-sun16 vconsole.keymap=us net.ifnames=0 biosdevname=0 rhgb quiet"

#grub2-mkconfig -o /boot/grub2/grub.cfg 

#ifconfig
ether 00:50:56:9d:70:4d

#cd /etc/sysconfig/network-scripts/
#mv ifcfg-ens32 ifcfg-eth0
#vi ifcfg-eth0 
HWADDR=00:50:56:9d:70:4d

BOOTPROTO=static

NAME=eth0

ONBOOT=yes
IPADDR=10.26.100.10
PREFIX=24

#ls /etc/udev/rules.d/
查看是否有70-persistent-net.rules的文件,如果有將其刪除


#reboot

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章