Static Routes
This chapter contains basic static routing configuration examples.
This example shows the complete configuration to enable static routing in a simple network topology. A static route is composed of a network prefix (host address) and a nexthop (gateway). Static routes are useful in small networks. They are simple solutions for making a few destinations reachable. Large networks use dynamic routing protocols.
Topology
Router R1 is configured with these static routes:
• The remote network 10.10.12.0/24
• The loopback address (host addresses) of router R2
• The loopback address of router R3
Figure 1-2: Basic Static Route
In all three routes, interface eth0 of router R2 is the gateway. Router R3 is configured with a default static route that is equivalent to configuring separate static routes with the same gateway or nexthop address. Router R2 has two routes, one for each of the remote routers' loopback address.
Last modified date: 07-13-2023