Table of Contents

Linux Commands#network

route - How to use route command in Linux with examples

show / manipulate the IP routing table

route comand options

~]# route -h
        -n, --numeric            don't resolve names

Display routing

route
route -n

Add routing

route add -net 192.168.10.0 netmask 255.255.255.0 gw 10.80.0.1
route add -host 192.168.0.100 gw 192.168.1.100
route add default gw 192.168.0.1

Delete routing

route del -net 192.168.10.0 netmask 255.255.255.0
route del -host 192.168.0.100
route del default

route del -host 192.168.0.100 gw 192.168.0.1
route del default gw 192.168.0.1