root@android:/ # busybox ifconfig eth0 192.168.0.116 netmask 255.255.255.0
root@android:/ # busybox ifconfig eth0 up
root@android:/ # busybox route add default gw 192.168.0.1 dev eth0
root@android:/ # setprop net.dsn1 219.146.1.66
root@android:/ # busybox ifconfig
eth0 Link encap:Ethernet HWaddr 1E:ED:19:27:1A:B3
inet addr:192.168.0.116 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::1ced:19ff:fe27:1ab3/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:2615 (2.5 KiB)
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:240 errors:0 dropped:0 overruns:0 frame:0
TX packets:240 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:17536 (17.1 KiB) TX bytes:17536 (17.1 KiB)
root@android:/ # ping 192.168.0.116
PING 192.168.0.116 (192.168.0.116) 56(84) bytes of data.
64 bytes from 192.168.0.116: icmp_seq=1 ttl=64 time=0.223 ms
64 bytes from 192.168.0.116: icmp_seq=2 ttl=64 time=0.119 ms
64 bytes from 192.168.0.116: icmp_seq=3 ttl=64 time=0.105 ms
root@android:/ # ping 192.168.0.1
PING 192.168.0.1 (192.168.0.1) 56(84) bytes of data.
From 192.168.0.116 icmp_seq=1 Destination Host Unreachable
From 192.168.0.116 icmp_seq=2 Destination Host Unreachable
From 192.168.0.116 icmp_seq=3 Destination Host Unreachable
|root@android:/ # busybox route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 192.168.0.1 0.0.0.0 UG 0 0 0 eth0
192.168.0.0 * 255.255.255.0 U 0 0 0 eth0
测试android下以太网,发现怎么设置RX的数据包都是0,而且网关看着设置的也有问题。有没有遇到相似问题的? |