
IP Routing Protocol-Independent Commands
78-20269-01 Command Line Interface Reference Guide
530
39
Use the no ip route command with the
ip-address
parameter to remove only one
static route to the given subnet via the given next hop.
Examples
Example 1 - The following example shows how to route packets for network
172.31.0.0 to a router at 172.31.6.6 using mask:
console(conf)#
ip route
172.31.0.0 255.255.0.0 172.31.6.6 metric 2
Example 2 - The following example shows how to route packets for network
172.31.0.0 to a router at 172.31.6.6 using prefix length:
console(conf)#
ip route
172.31.0.0 /16 172.31.6.6 metric 2
Example 3 - The following example shows how to reject packets for network
194.1.1.0:
console(conf)#
ip route
194.1.1.0 255.255.255.0 reject-route
Example 4 - The following example shows how to remove all static routes to
network 194.1.1.0/24:
console(conf)#
no ip route
194.1.1.0 /24
Example 5 - The following example shows how to remove one static route to
network 194.1.1.0/24 via 1.1.1.1:
console(conf)#
no ip route
194.1.1.0 /24 1.1.1.1
39.2
show ip route
Use the show ip route EXEC mode command to display the current routing table
state.