2 show ip route, Show ip route – PLANET XGS3-24040 User Manual
Page 404
![background image](https://www.manualsdir.com/files/865186/content/doc404.png)
30-117
The direct route has the highest priority when each route management distance value remain
unchanged and followed by static route, EBGP、OSPF、RIP、IBGP.
Example:
Example 1. Add a static route
Switch(config)#ip route 1.1.1.0 255.255.255.0 2.1.1.1
Example 2. Add default route
Switch(config)#ip route 0.0.0.0 0.0.0.0 2.2.2.1
30.2 show ip route
Command:
show ip route [<destination>|<destination >|<length>|connected | static | rip| ospf | bgp | isis|
kernel| statistics| database [connected | static | rip| ospf | bgp | isis| kernel] |fib[statistics]]
Function:
Show the route table.
Parameter:
<destination> is the destination network address; <destination >/<length> is the destination
network address plus the length of prefix; connected is direct route; static is static route; rip is RIP
route; ospf is OSPF route; bgp is BGP route; isis is ISIS route; kernel is kernel route; statistics
shows the number of routes; database is route database; fib is kernel route table.
Command Mode:
Admin mode
Usage Guide:
Show all the contents in the route table including: route type, destination network, mask, next-hop
address, interface, etc
Example:
switch#show ip route
Codes: K - kernel, C - connected, S - static, R - RIP, B - BGP
O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default
Gateway of last resort is 210.0.0.3 to network 0.0.0.0
S* 0.0.0.0/0 [1/0] via 210.0.0.3, Vlan1
C 127.0.0.0/8 is directly connected, Loopback
O IA 172.16.11.0/24 [110/40] via 210.14.0.1, Vlan3014, 00:00:47
O IA 172.16.12.0/24 [110/40] via 210.14.0.1, Vlan3014, 00:00:47
O IA 172.16.13.0/24 [110/40] via 210.14.0.1, Vlan3014, 00:00:47
O IA 172.16.14.0/24 [110/40] via 210.14.0.1, Vlan3014, 00:00:47