Static Routing
Static
routing occurs when you manually add routes in each router’s routing table. Static routing has the following benefits:
No CPU
overhead
No bandwidth
usage between routers
Only
Administrator can choose allowed network
Static routing has the following
disadvantages:
Administrator must really understand the internetwork and how each
router is connected
in order to
configure routes correctly.
Administrator
has to add a route to it on all Routers manually.
Not feasible
in large networks because maintaining it would be a full-time job in itself
Command Syntax
ip route [destination_network] [mask] [next-hop_address or
exitinterface]
[administrative_distance] [permanent]
IP route:- The command used to create the static route.
Destination network: - The network you’re placing in the
routing table.
Mask: - The subnet mask being used on the
network.
Next-hop address:-The address of the next-hop router
that will receive the packet and forward
it to the remote network.
Exit interface: - You can use it in place of the
next-hop address if you want, but it’s got
to be on a point-to-point link, such as a WAN. This command won’t
work on a LAN such
as Ethernet.
Administrative distance :- By default, static routes have an administrative distance of 1 (or
even 0 if you use an exit interface instead of a next-hop
address). You can change the default
value by adding an administrative weight at the end of the command.
Permanent :-If the interface is shut down, or the router can’t communicate to
the next-hop
router, the route will automatically be discarded from the routing
table. Choosing the permanent
option keeps
the entry in the routing table no matter what happens.
Example:-
Router(config)#ip route 172.16.3.0 255.255.255.0
192.168.2.4
The ip
route command tells us
simply that it is a static route.
172.16.3.0 is the remote network we want to send packets to.
255.255.255.0 is the mask of the remote network.
192.168.2.4
is the next hop, or router, we will send packets to.
In this topology we are going to configure Default Routing on R1
To configure default routing on R1 command is :-
Default Routing
We use default routing to send packets with a remote
destination network not in the routing
table to the next-hop router. You can only use default routing on
stub networks those with
only one exit
path out of the network.
To configure a default route, you use wildcards in the network
address and mask locations
of a static
route.
R1(config)#ip route 0.0.0.0 0.0.0.0 10.1.1.2
To check routing table command is
R1#show ip route
No comments:
Post a Comment