104 CHAPTER 6: IP ROUTING P ROTOCOL OPERATIONthe optimal route. For example, routing through three LAN route segments maybe much faster than routing through two WAN route segments.Configuring the IP Routing Protocol is described in the following sections:■ Selecting Routes Through the Routing Table■ Routing Management PolicySelecting RoutesThrough the RoutingTableFor a router, the routing table is the key to forwarding packets. Each router saves arouting table in its memory, and each entry in this table specifies the physical portof the router through which a packet is sent to a subnet or a host. The packet canreach the next router over a particular path or reach a destination host through adirectly connected network.A routing table has the following key entries:■ A destination address — Identifies the destination IP address or the destinationnetwork of the IP packet, which is 32 bits in length.■ A network mask — Made up of several consecutive 1s, which can be expressedeither in the dotted decimal format, or by the number of the consecutive 1s inthe mask. Combined with the destination address, the network mask identifiesthe network address of the destination host or router. With the destinationaddress and the network mask, you have the address of the network segmentwhere the destination host or router is located. For example, if the destinationaddress is 129.102.8.10, the address of the network where the host or therouter with the mask 255.255.0.0 is located is 129.102.0.0.■ The output interface — Indicates an interface through which an IP packetshould be forwarded.■ The next hop address — Indicates the next router that an IP packet will passthrough.■ The priority added to the IP routing table for a route — Indicates the type ofroute that is selected. There may be multiple routes with different next hops tothe same destination. These routes can be discovered by different routingprotocols, or they can be the static routes that are configured manually. Theroute with the highest priority (the smallest numerical value) is selected as thecurrent optimal route.Routes are divided into the following types: subnet routes, in which thedestination is a subnet, or host routes, in which the destination is a host.In addition, depending on whether the network of the destination host is directlyconnected to the router, there are the following types of routes:■ Direct route — The router is directly connected to the network where thedestination is located.■ Indirect route — The router is not directly connected to the network where thedestination is located.To limit the size of the routing table, an option is available to set a default route.All the packets that fail to find a suitable table entry are forwarded through thisdefault route.