adb shell network ip tools reference

From thelinuxwiki
Jump to: navigation, search

to check network interfaces, use netcfg instead of trying ifconfg

# netcfg

routes

to view main routing table only

# ip route show

to view ip rules (whatever those are...)

# ip rule show
# ip route add 192.168.15.0/24 via 192.168.35.1 dev tun0
ip route del 10.10.10.0/24 via 192.168.1.1 dev eth0
ip route del default via 192.168.1.1 dev eth0
ip route list table all 
ip route change table wifi default via 192.168.1.1 dev eth0

thorough guide:

http://linux-ip.net/html/tools-ip-route.html