Linux API/network2009. 8. 18. 11:16
이 녀석들은 데비안 출신이었나?

5.3.5. The network interface with the static IP

The network interface served by the static IP is configured by creating the configuration entry in the "/etc/network/interfaces" file as the following.

allow-hotplug eth0
iface eth0 inet static
address 192.168.11.100
netmask 255.255.255.0
broadcast 192.168.11.255
gateway 192.168.11.1
dns-domain lan
dns-nameservers 192.168.11.1

When the Linux kernel detects the physical interface eth0, the allow-hotplug stanza will cause ifup to bring up the interface and the iface stanza will cause ifup to use the static IP to configure the interface.


[링크 : http://www.debian.org/doc/manuals/debian-reference/ch05.en.html#_the_network_interface_with_the_static_ip]


간단하게 해석하자면, 물리적으로 연결이 되었음을 탐지하게 되면, 자동으로 설정을 실행한다는 의미이다.
(interface-eth0-를 up 시키고 iface구절을 실행함)


Check to see if a Network Link/Interface is up|down

ip link show eth0
//the iproute package is required. If there is no ip package, apt-get install iproute

If eth0 has a Network link, the following will be returned:
2: eth0: <BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast qlen 1000
link/ether 00:0c:29:26:57:4e brd ff:ff:ff:ff:ff:ff

If eth0 has no Network link, the following will be returned:
2: eth0: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast qlen 1000
link/ether 00:0c:29:26:57:4e brd ff:ff:ff:ff:ff:ff

The "UP" is the operative word.


[링크 : http://wiki.kartbuilding.net/index.php/Ifup-ifdown]


실제로 ifup, ifdown 시에 제대로 interface가 up / down 되었는지 확인하는 방법이다.
Posted by 구차니