The following is sample output from the show iproute command when an IP address is not specified:
Device# show ip route
Codes: R - RIP derived, O - OSPF derived,
C - connected, S - static, B - BGP derived,
* - candidate default route, IA - OSPF inter area route,
i - IS-IS derived, ia - IS-IS, U - per-user static route,
o - on-demand routing, M - mobile, P - periodic downloaded static route,
D - EIGRP, EX - EIGRP external, E1 - OSPF external type 1 route,
E2 - OSPF external type 2 route, N1 - OSPF NSSA external type 1 route,
N2 - OSPF NSSA external type 2 route
Gateway of last resort is 10.119.254.240 to network 10.140.0.0
O E2 10.110.0.0 [160/5] via 10.119.254.6, 0:01:00, Ethernet2
E 10.67.10.0 [200/128] via 10.119.254.244, 0:02:22, Ethernet2
O E2 10.68.132.0 [160/5] via 10.119.254.6, 0:00:59, Ethernet2
O E2 10.130.0.0 [160/5] via 10.119.254.6, 0:00:59, Ethernet2
E 10.128.0.0 [200/128] via 10.119.254.244, 0:02:22, Ethernet2
E 10.129.0.0 [200/129] via 10.119.254.240, 0:02:22, Ethernet2
E 10.65.129.0 [200/128] via 10.119.254.244, 0:02:22, Ethernet2
E 10.10.0.0 [200/128] via 10.119.254.244, 0:02:22, Ethernet2
E 10.75.139.0 [200/129] via 10.119.254.240, 0:02:23, Ethernet2
E 10.16.208.0 [200/128] via 10.119.254.244, 0:02:22, Ethernet2
E 10.84.148.0 [200/129] via 10.119.254.240, 0:02:23, Ethernet2
E 10.31.223.0 [200/128] via 10.119.254.244, 0:02:22, Ethernet2
E 10.44.236.0 [200/129] via 10.119.254.240, 0:02:23, Ethernet2
E 10.141.0.0 [200/129] via 10.119.254.240, 0:02:22, Ethernet2
E 10.140.0.0 [200/129] via 10.119.254.240, 0:02:23, Ethernet2
The following sample output from the show ip routes command includes routes learned from IS-IS Level 2:
Device# show ip route
Codes: R - RIP derived, O - OSPF derived,
C - connected, S - static, B - BGP derived,
* - candidate default route, IA - OSPF inter area route,
i - IS-IS derived, ia - IS-IS, U - per-user static route,
o - on-demand routing, M - mobile, P - periodic downloaded static route,
D - EIGRP, EX - EIGRP external, E1 - OSPF external type 1 route,
E2 - OSPF external type 2 route, N1 - OSPF NSSA external type 1 route,
N2 - OSPF NSSA external type 2 route
Gateway of last resort is not set
10.89.0.0 is subnetted (mask is 255.255.255.0), 3 subnets
C 10.89.64.0 255.255.255.0 is possibly down,
routing via 0.0.0.0, Ethernet0
i L2 10.89.67.0 [115/20] via 10.89.64.240, 0:00:12, Ethernet0
i L2 10.89.66.0 [115/20] via 10.89.64.240, 0:00:12, Ethernet0
The following is sample output from the show ip route
ip-address mask
longer-prefixes command. When this keyword is included, the address-mask pair becomes the prefix, and any address that matches that prefix
is displayed. Therefore, multiple addresses are displayed. The logical AND operation is performed on the source address 0.0.0.0
and the mask 0.0.0.0, resulting in 0.0.0.0. Each destination in the routing table is also logically ANDed with the mask and
compared with 0.0.0.0. Any destinations that fall into that range are displayed in the output.
Device# show ip route 0.0.0.0 0.0.0.0 longer-prefixes
Codes: R - RIP derived, O - OSPF derived,
C - connected, S - static, B - BGP derived,
* - candidate default route, IA - OSPF inter area route,
i - IS-IS derived, ia - IS-IS, U - per-user static route,
o - on-demand routing, M - mobile, P - periodic downloaded static route,
D - EIGRP, EX - EIGRP external, E1 - OSPF external type 1 route,
E2 - OSPF external type 2 route, N1 - OSPF NSSA external type 1 route,
N2 - OSPF NSSA external type 2 route
Gateway of last resort is not set
S 10.134.0.0 is directly connected, Ethernet0
S 10.10.0.0 is directly connected, Ethernet0
S 10.129.0.0 is directly connected, Ethernet0
S 10.128.0.0 is directly connected, Ethernet0
S 10.49.246.0 is directly connected, Ethernet0
S 10.160.97.0 is directly connected, Ethernet0
S 10.153.88.0 is directly connected, Ethernet0
S 10.76.141.0 is directly connected, Ethernet0
S 10.75.138.0 is directly connected, Ethernet0
S 10.44.237.0 is directly connected, Ethernet0
S 10.31.222.0 is directly connected, Ethernet0
S 10.16.209.0 is directly connected, Ethernet0
S 10.145.0.0 is directly connected, Ethernet0
S 10.141.0.0 is directly connected, Ethernet0
S 10.138.0.0 is directly connected, Ethernet0
S 10.128.0.0 is directly connected, Ethernet0
10.19.0.0 255.255.255.0 is subnetted, 1 subnets
C 10.19.64.0 is directly connected, Ethernet0
10.69.0.0 is variably subnetted, 2 subnets, 2 masks
C 10.69.232.32 255.255.255.240 is directly connected, Ethernet0
S 10.69.0.0 255.255.0.0 is directly connected, Ethernet0
The following sample outputs from the show ip route command display all downloaded static routes. A “p” indicates that these routes were installed using the AAA route download
function.
Device# show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, * - candidate default
U - per-user static route, o - ODR, P - periodic downloaded static route
T - traffic engineered route
Gateway of last resort is 172.16.17.1 to network 10.0.0.0
172.31.0.0/32 is subnetted, 1 subnets
P 172.31.229.41 is directly connected, Dialer1 0.0.0.0/0 is subnetted, 3 subnets
P 10.1.1.0 [200/0] via 172.31.229.41, Dialer1
P 10.1.3.0 [200/0] via 172.31.229.41, Dialer1
P 10.1.2.0 [200/0] via 172.31.229.41, Dialer1
Device# show ip route static
172.16.4.0/8 is variably subnetted, 2 subnets, 2 masks
P 172.16.1.1/32 is directly connected, BRI0
P 172.16.4.0/8 [1/0] via 10.1.1.1, BRI0
S 172.31.0.0/16 [1/0] via 172.16.114.65, Ethernet0
S 0.0.0.0/0 is directly connected, BRI0
P 0.0.0.0/0 is directly connected, BRI0
172.16.0.0/16 is variably subnetted, 5 subnets, 2 masks
S 172.16.114.201/32 is directly connected, BRI0
S 172.16.114.205/32 is directly connected, BRI0
S 172.16.114.174/32 is directly connected, BRI0
S 172.16.114.12/32 is directly connected, BRI0
P 0.0.0.0/8 is directly connected, BRI0
P 0.0.0.0/16 is directly connected, BRI0
P 10.2.2.0/24 is directly connected, BRI0
S* 0.0.0.0/0 [1/0] via 172.16.114.65, Ethernet0
S 172.16.0.0/16 [1/0] via 172.16.114.65, Ethernet0
The following sample output from the show ip route static download command displays all active and inactive routes installed using the AAA route download function:
Device# show ip route static download
Connectivity: A - Active, I - Inactive
A 10.10.0.0 255.0.0.0 BRI0
A 10.11.0.0 255.0.0.0 BRI0
A 10.12.0.0 255.0.0.0 BRI0
A 10.13.0.0 255.0.0.0 BRI0
I 10.20.0.0 255.0.0.0 172.21.1.1
I 10.22.0.0 255.0.0.0 Serial0
I 10.30.0.0 255.0.0.0 Serial0
I 10.31.0.0 255.0.0.0 Serial1
I 10.32.0.0 255.0.0.0 Serial1
A 10.34.0.0 255.0.0.0 192.168.1.1
A 10.36.1.1 255.255.255.255 BRI0 200 name remote1
I 10.38.1.9 255.255.255.0 192.168.69.1
The following sample outputs from the show ip route nhrp command display shortcut switching on the tunnel interface:
Device# show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
Gateway of last resort is not set
0.0.0.0/16 is variably subnetted, 3 subnets, 2 masks
C 10.1.1.0/24 is directly connected, Tunnel0
C 172.16.22.0 is directly connected, Ethernet1/0
H 172.16.99.0 [250/1] via 10.1.1.99, 00:11:43, Tunnel0
10.11.0.0/24 is subnetted, 1 subnets
C 10.11.11.0 is directly connected, Ethernet0/0
Device# show ip route nhrp
H 172.16.99.0 [250/1] via 10.1.1.99, 00:11:43, Tunnel0
The following are sample outputs from the show ip route command when the next-hop-override keyword is used. When this keyword is included, the NHRP next-hop overrides that are associated with a particular route and
the corresponding default next hops are displayed.
===============================================================
1) Initial configuration
===============================================================
Device# show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
+ - replicated route
Gateway of last resort is not set
10.2.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 10.2.1.0/24 is directly connected, Loopback1
L 10.2.1.1/32 is directly connected, Loopback1
0.0.0.0/24 is subnetted, 1 subnets
S 10.10.10.0 is directly connected, Tunnel0
10.11.0.0/24 is subnetted, 1 subnets
S 10.11.11.0 is directly connected, Ethernet0/0
Device# show ip route next-hop-override
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
+ - replicated route
Gateway of last resort is not set
10.2.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 10.2.1.0/24 is directly connected, Loopback1
L 10.2.1.1/32 is directly connected, Loopback1
10.0.0.0/24 is subnetted, 1 subnets
S 10.10.10.0 is directly connected, Tunnel0
10.11.0.0/24 is subnetted, 1 subnets
S 10.11.11.0 is directly connected, Ethernet0/0
Device# show ip cef
Prefix Next Hop Interface
.
.
.
10.2.1.255/32 receive Loopback1
10.10.10.0/24 attached Tunnel0 <<<<<<<<
10.11.11.0/24 attached Ethernet0/0
172.16.0.0/12 drop
.
.
.
===============================================================
2) Add a next-hop override
address = 10.10.10.0
mask = 255.255.255.0
gateway = 10.1.1.1
interface = Tunnel0
===============================================================
Device# show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
+ - replicated route
Gateway of last resort is not set
10.2.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 10.2.1.0/24 is directly connected, Loopback1
L 10.2.1.1/32 is directly connected, Loopback1
10.0.0.0/24 is subnetted, 1 subnets
S 10.10.10.0 is directly connected, Tunnel0
10.11.0.0/24 is subnetted, 1 subnets
S 10.11.11.0 is directly connected, Ethernet0/0
Device# show ip route next-hop-override
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
+ - replicated route
Gateway of last resort is not set
10.2.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 10.2.1.0/24 is directly connected, Loopback1
L 10.2.1.1/32 is directly connected, Loopback1
10.0.0.0/24 is subnetted, 1 subnets
S 10.10.10.0 is directly connected, Tunnel0
[NHO][1/0] via 10.1.1.1, Tunnel0
10.11.0.0/24 is subnetted, 1 subnets
S 10.11.11.0 is directly connected, Ethernet0/0
Device# show ip cef
Prefix Next Hop Interface
.
.
.
10.2.1.255/32 receive Loopback110.10.10.0/24
10.10.10.0/24 10.1.1.1 Tunnel0
10.11.11.0/24 attached Ethernet0/0
10.12.0.0/16 drop
.
.
.
===============================================================
3) Delete a next-hop override
address = 10.10.10.0
mask = 255.255.255.0
gateway = 10.11.1.1
interface = Tunnel0
===============================================================
Device# show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
+ - replicated route
Gateway of last resort is not set
10.2.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 10.2.1.0/24 is directly connected, Loopback1
L 10.2.1.1/32 is directly connected, Loopback1
10.0.0.0/24 is subnetted, 1 subnets
S 10.10.10.0 is directly connected, Tunnel0
10.11.0.0/24 is subnetted, 1 subnets
S 10.11.11.0 is directly connected, Ethernet0/0
Device# show ip route next-hop-override
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
+ - replicated route
Gateway of last resort is not set
10.2.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 10.2.1.0/24 is directly connected, Loopback1
L 10.2.1.1/32 is directly connected, Loopback1
10.0.0.0/24 is subnetted, 1 subnets
S 10.10.10.0 is directly connected, Tunnel0
10.11.0.0/24 is subnetted, 1 subnets
S 10.11.11.0 is directly connected, Ethernet0/0
Device# show ip cef
Prefix Next Hop Interface
.
.
.
10.2.1.255/32 receive Loopback110.10.10.0/24
10.10.10.0/24 attached Tunnel0
10.11.11.0/24 attached Ethernet0/0
10.120.0.0/16 drop
.
.
.
The table below describes the significant fields shown in the displays:
Table 24. show ip route Field Descriptions
Field
|
Description
|
Codes (Protocol)
|
Indicates the protocol that derived the route. It can be one of the following values:
-
B—BGP derived
-
C—Connected
-
D—Enhanced Interior Gateway Routing Protocol (EIGRP)
-
EX—EIGRP external
-
H—NHRP
-
i—IS-IS derived
-
ia—IS-IS
-
L—Local
-
M—Mobile
-
o—On-demand routing
-
O—Open Shortest Path First (OSPF) derived
-
P—Periodic downloaded static route
-
R—Routing Information Protocol (RIP) derived
-
S—Static
-
U—Per-user static route
-
+—Replicated route
|
Codes (Type)
|
Type of route. It can be one of the following values:
-
*—Indicates the last path used when a packet was forwarded. This information is specific to nonfast-switched packets.
-
E1—OSPF external type 1 route
-
E2—OSPF external type 2 route
-
IA—OSPF interarea route
-
L1—IS-IS Level 1 route
-
L2—IS-IS Level 2 route
-
N1—OSPF not-so-stubby area (NSSA) external type 1 route
-
N2—OSPF NSSA external type 2 route
|
10.110.0.0
|
Indicates the address of the remote network.
|
[160/5]
|
The first number in brackets is the administrative distance of the information source; the second number is the metric for
the route.
|
via 10.119.254.6
|
Specifies the address of the next device to the remote network.
|
0:01:00
|
Specifies the last time the route was updated (in hours:minutes:seconds).
|
Ethernet2
|
Specifies the interface through which the specified network can be reached.
|
The following example shows that IP route 10.8.8.0 is directly connected to the Internet and is the next-hop (option 3) default
gateway. Routes 10.1.1.1 [1/0], 10.3.2.1 [24/0], and 172.16.2.2 [1/0] are static, and route 0.0.0.0/0 is a default route candidate.
The fields in the display are self-explanatory.
Device# show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route
Gateway of last resort is 10.0.19.14 to network 0.0.0.0
10.0.0.0/24 is subnetted, 1 subnets
C 10.8.8.0 is directly connected, Ethernet1
10.0.0.0/32 is subnetted, 1 subnets
S 10.1.1.1 [1/0] via 10.8.8.1
10.0.0.0/32 is subnetted, 1 subnets
S 10.3.2.1 [24/0] via 10.8.8.1
172.16.0.0/32 is subnetted, 1 subnets
S 172.16.2.2 [1/0] via 10.8.8.1
10.0.0.0/28 is subnetted, 1 subnets
C 10.0.19.0 is directly connected, Ethernet0
10.0.0.0/24 is subnetted, 1 subnets
C 10.15.15.0 is directly connected, Loopback0
S* 10.0.0.0/0 [1/0] via 10.0.19.14
The following sample output from the show ip route repair-paths command shows repair paths marked with the tag [RPR]. The fields in the display are self-explanatory:
Device# show ip route repair-paths
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, 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, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP
+ - replicated route, % - next hop override
Gateway of last resort is not set
10.0.0.0/32 is subnetted, 3 subnets
C 10.1.1.1 is directly connected, Loopback0
B 10.2.2.2 [200/0] via 172.16.1.2, 00:31:07
[RPR][200/0] via 192.168.1.2, 00:31:07
B 10.9.9.9 [20/0] via 192.168.1.2, 00:29:45
[RPR][20/0] via 192.168.3.2, 00:29:45
172.16.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 172.16.1.0/24 is directly connected, Ethernet0/0
L 172.16.1.1/32 is directly connected, Ethernet0/0
192.168.1.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.1.0/24 is directly connected, Serial2/0
L 192.168.1.1/32 is directly connected, Serial2/0
B 192.168.3.0/24 [200/0] via 172.16.1.2, 00:31:07
[RPR][200/0] via 192.168.1.2, 00:31:07
B 192.168.9.0/24 [20/0] via 192.168.1.2, 00:29:45
[RPR][20/0] via 192.168.3.2, 00:29:45
B 192.168.13.0/24 [20/0] via 192.168.1.2, 00:29:45
[RPR][20/0] via 192.168.3.2, 00:29:45
Device# show ip route repair-paths 10.9.9.9
>Routing entry for 10.9.9.9/32
> Known via "bgp 100", distance 20, metric 0
> Tag 10, type external
> Last update from 192.168.1.2 00:44:52 ago
> Routing Descriptor Blocks:
> * 192.168.1.2, from 192.168.1.2, 00:44:52 ago, recursive-via-conn
> Route metric is 0, traffic share count is 1
> AS Hops 2
> Route tag 10
> MPLS label: none
> [RPR]192.168.3.2, from 172.16.1.2, 00:44:52 ago
> Route metric is 0, traffic share count is 1
> AS Hops 2
> Route tag 10
> MPLS label: none