# ROUTE

* **shows and manipulates the IP routing table**

**# route add -net 10.10.10.0/24 gw 192.168.0.1**

* **adds a route**

**# route del -net 10.10.10.0/24 gw 192.168.0.1**

* **deletes a route**

**# route add default gw 192.168.0.1**

* **adds default gateway**

**route command also shows and manipulate ip routing table. To see default routing table in Linux, type the following command.**<br>

**# route**<br>

**Kernel IP routing table**

**Destination     Gateway         Genmask         Flags Metric Ref    Use Iface**

**192.168.50.0    \*               255.255.255.0   U     0      0        0 eth0**

**link-local      \*               255.255.0.0     U     1002   0        0 eth0**

**default         192.168.50.1    0.0.0.0         UG    0      0        0 eth0**<br>

**Adding, deleting routes and default Gateway with following commands.**

**Route Adding**<br>

**# route add -net 10.10.10.0/24 gw 192.168.0.1**<br>

**Route Deleting**<br>

**# route del -net 10.10.10.0/24 gw 192.168.0.1**<br>

**Adding default Gateway**<br>

**# route add default gw 192.168.0.1**<br>
