在openwrt的路由器上,如果telnet(或ssh)进去后,使用ifconfig会看到如下接口:
-
root@OpenWrt:/# ifconfig
-
br-lan Link encap:Ethernet HWaddr 00:64:18:23:01:29
-
inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0
-
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
-
RX packets:29318 errors:0 dropped:980 overruns:0 frame:0
-
TX packets:23960 errors:0 dropped:0 overruns:0 carrier:0
-
collisions:0 txqueuelen:0
-
RX bytes:3621134 (3.4 MiB) TX bytes:7020725 (6.6 MiB)
-
-
eth0 Link encap:Ethernet HWaddr 00:64:18:23:01:29
-
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
-
RX packets:29318 errors:0 dropped:0 overruns:0 frame:0
-
TX packets:23960 errors:0 dropped:0 overruns:0 carrier:0
-
collisions:0 txqueuelen:1000
-
RX bytes:4031586 (3.8 MiB) TX bytes:7020725 (6.6 MiB)
-
Interrupt:4
使用brctl show br-lan还能看到如下结果:
-
root@OpenWrt:/# brctl show br-lan
-
bridge name bridge id STP enabled interfaces
-
br-lan 7fff.006418230129 no eth0
那么,这个eth0是保存在哪的呢?或者说是这么获取到的?怎么判断eth0就是lan口呢?
阅读(1481) | 评论(0) | 转发(0) |