udev: renamed network interface eth0 to eth1
RHEL6 에서 KVM등을 이용하여 가상서버를 운영시 마스터 이미지를 통해 새로운 VM을 만들면
해당 VM의 네트워크 디바이스명이 eth0가 아닌 eth1 이나 eth2등으로 변경되어 진다.
최초 상태인 eth0로 원복하기 위해서는 아래 절차가 필요하다.
# vi /etc/udev/rules.d/70-persistent-net.rules
————————————————————————————-
# This file was automatically generated by the /lib/udev/write_net_rules
# program, run by the persistent-net-generator.rules rules file.
#
# You can modify it, as long as you keep each rule on a single
# line, and change only the value of the NAME= key.
# PCI device 0x1af4:0x1000 (virtio-pci)
# SUBSYSTEM==”net”, ACTION==”add”, DRIVERS==”?*”, ATTR{address}==”52:54:00:78:10:fb”, ATTR{type}==”1″, KERNEL==”eth*”, NAME=”eth0″ -> 이줄 주석 처리
# PCI device 0x1af4:0x1000 (virtio-pci)
SUBSYSTEM==”net”, ACTION==”add”, DRIVERS==”?*”, ATTR{address}==”00:16:3e:65:03:d7″, ATTR{type}==”1″, KERNEL==”eth*”, NAME=”eth1″
위의 설정 행 중 NAME 값을 eth0로 변경..
SUBSYSTEM==”net”, ACTION==”add”, DRIVERS==”?*”, ATTR{address}==”00:16:3e:65:03:d7″, ATTR{type}==”1″, KERNEL==”eth*”, NAME=”eth0″
————————————————————————————–
리부팅하면 된다.
—————————————————————————————
Can you be more specific about the content of your article? After reading it, I still have some doubts. Hope you can help me.
Your article helped me a lot, is there any more related content? Thanks!