December 2006
Intermediate to advanced
1188 pages
72h 8m
English
You want to configure a static route.
You can configure a static route with the ip route command, as follows:
Router#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router(config)#ip route10.35.15.5 255.255.255.255Ethernet0Router(config)#endRouter#
You can also configure a static route to point to a particular next hop router:
Router#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router(config)#interfaceRouter(config-if)#Serial0ip addressRouter(config-if)#10.35.6.2 255.255.255.0exitRouter(config)#ip routeRouter(config)#172.16.0.0 255.255.0.0 10.35.6.1 2endRouter#
If you want to ensure a route remains in place even if the next-hop IP address becomes unreachable, or the interface goes down, you can use the permanent keyword:
Router#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router(config)#ip route10.35.15.5 255.255.255.255Ethernet0 permanentRouter(config)#ip route172.16.0.0 255.255.0.0 10.35.6.1 2permanentRouter(config)#endRouter#
You can also manually configure routing tags that use static routes by using the tag keyword:
Router#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router(config)#ip route172.16.0.0 255.255.0.0 10.35.6.1 2tagRouter(config)#36291endRouter#
The first version sends all packets destined to the single host
10.35.15.5 out through the Ethernet0 interface. In this case, ...