Home > Articles > Cisco Network Technology > General Networking > Cisco Networking Academy's Introduction to Routing Dynamically

Cisco Networking Academy's Introduction to Routing Dynamically

  • Sample Chapter is provided courtesy of Cisco Press.
  • Date: Mar 24, 2014.

Chapter Description

This chapter explains multiple routing protocols (particularly dynamic routing protocols) and describes their relative strengths and weaknesses. It also shows how to read a routing table easily and interpret the IPv6 routing information listed within it.

RIP and RIPng Routing (3.3)

Although the use of RIP has decreased in the past decade, it is still important to your networking studies because it might be encountered in a network implementation. As well, understanding how RIP operates and knowing its implementation will make learning other routing protocols easier.

Configuring the RIP Protocol (3.3.1)

In this section, you will learn how to configure, verify, and troubleshoot RIPv2.

Router RIP Configuration Mode (3.3.1.1)

Although RIP is rarely used in modern networks, it is useful as a foundation for understanding basic network routing. For this reason, this section provides a brief overview of how to configure basic RIP settings and to verify RIPv2.

Refer to the reference topology in Figure 3-22 and the addressing table in Table 3-7.

Figure 3-22

Figure 3-22 RIP Reference Topology

Table 3-7 Addressing Table

Device

Interface

IP Address

Subnet Mask

R1

G0/0

192.168.1.1

255.255.255.0

S0/0/0

192.168.2.1

255.255.255.0

R2

G0/0

192.168.3.1

255.255.255.0

S0/0/0

192.168.2.2

255.255.255.0

S0/0/1

192.168.4.2

255.255.255.0

R3

G0/0

192.168.5.1

255.255.255.0

S0/0/1

192.168.4.1

255.255.255.0

In this scenario, all routers have been configured with basic management features and all interfaces identified in the reference topology are configured and enabled. There are no static routes configured and no routing protocols enabled; therefore, remote network access is currently impossible. RIPv2 is used as the dynamic routing protocol.

To enable RIP, use the router rip command to enter router configuration mode, as shown in the following output. This command does not directly start the RIP process. Instead, it provides access to the router configuration mode where the RIP routing settings are configured.

R1# conf t

Enter configuration commands, one per line. End with CNTL/Z.

R1(config)# router rip

R1(config-router)#

To disable and eliminate RIP, use the no router rip global configuration command. This command stops the RIP process and erases all existing RIP configurations.

Figure 3-23 displays a partial list of the various RIP commands that can be configured. This section covers the two highlighted commands as well as network, passive-interface, and version.

Figure 3-23

Figure 3-23 RIP Configuration Options

Advertising Networks (3.3.1.2)

By entering the RIP router configuration mode, the router is instructed to run RIP. But the router still needs to know which local interfaces it should use for communication with other routers, as well as which locally connected networks it should advertise to those routers.

To enable RIP routing for a network, use the network network-address router configuration mode command. Enter the classful network address for each directly connected network. This command:

  • Enables RIP on all interfaces that belong to a specific network. Associated interfaces now both send and receive RIP updates.
  • Advertises the specified network in RIP routing updates sent to other routers every 30 seconds.

In the following command sequence, the network command is used to advertise the R1 directly connected networks.

R1(config)# router rip

R1(config-router)# network 192.168.1.0

R1(config-router)# network 192.168.2.0

R1(config-router)#

Examining Default RIP Settings (3.3.1.3)

The output of the show ip protocols command in Figure 3-24 displays the IPv4 routing protocol settings currently configured on the router.

Figure 3-24

Figure 3-24 Verifying RIP Settings on R1

This output confirms that:

  1. RIP routing is configured and running on router R1.
  2. The values of various timers; for example, the next routing update is sent by R1 in 16 seconds.
  3. The version of RIP configured is currently RIPv1.
  4. R1 is currently summarizing at the classful network boundary.
  5. The classful networks are advertised by R1. These are the networks that R1 includes in its RIP updates.
  6. The RIP neighbors are listed, including their next-hop IP address, the associated AD that R2 uses for updates sent by this neighbor, and when the last update was received from this neighbor.

The show ip route command displays the RIP routes installed in the routing table. In Figure 3-25, R1 now knows about the highlighted networks.

Figure 3-25

Figure 3-25 Verifying RIP Routes on R1

Enabling RIPv2 (3.3.1.4)

By default, when a RIP process is configured on a Cisco router, it is running RIPv1, as shown in the following output:

R1# show ip protocols

*** IP Routing is NSF aware ***



Routing Protocol is "rip"

  Outgoing update filter list for all interfaces is not set

  Incoming update filter list for all interfaces is not set

  Sending updates every 30 seconds, next due in 16 seconds

  Invalid after 180 seconds, hold down 180, flushed after 240

  Redistributing: rip

  Default version control: send version 1, receive any version

    Interface             Send  Recv  Triggered RIP  Key-chain

    GigabitEthernet0/0    1     1 2

    Serial0/0/0           1     1 2

  Automatic network summarization is in effect

  Maximum path: 4

  Routing for Networks:

    192.168.1.0

    192.168.2.0

  Routing Information Sources:

    Gateway         Distance      Last Update

    192.168.2.2          120      00:00:15

  Distance: (default is 120)



R1#

However, even though the router only sends RIPv1 messages, it can interpret both RIPv1 and RIPv2 messages. A RIPv1 router ignores the RIPv2 fields in the route entry.

Use the version 2 router configuration mode command to enable RIPv2, as shown in Figure 3-26.

Figure 3-26

Figure 3-26 Enable and Verify RIPv2 on R1

Notice how the show ip protocols command verifies that R2 is now configured to send and receive version 2 messages only. The RIP process now includes the subnet mask in all updates, making RIPv2 a classless routing protocol.

The following output verifies that there are no RIP routes still in the routing table:

R1# show ip route | begin Gateway

Gateway of last resort is not set



      192.168.1.0/24 is variably subnetted, 2 subnets, 2 masks

C        192.168.1.0/24 is directly connected, GigabitEthernet0/0

L        192.168.1.1/32 is directly connected, GigabitEthernet0/0

      192.168.2.0/24 is variably subnetted, 2 subnets, 2 masks

C        192.168.2.0/24 is directly connected, Serial0/0/0

L        192.168.2.1/32 is directly connected, Serial0/0/0

R1#

There are no RIP routes because R1 is now only listening for RIPv2 updates. R2 and R3 are still sending RIPv1 updates. Therefore, the version 2 command must be configured on all routers in the routing domain.

Disabling Auto Summarization (3.3.1.5)

As shown in Figure 3-27, RIPv2 automatically summarizes networks at major network boundaries by default, just like RIPv1.

Figure 3-27

Figure 3-27 Verify RIPv2 Route Summarization

To modify the default RIPv2 behavior of automatic summarization, use the no auto-summary router configuration mode command as shown in the following command sequence:

R1(config)# router rip

R1(config-router)# no auto-summary

R1(config-router)# end

R1#

*Mar 10 14:11:49.659: %SYS-5-CONFIG_I: Configured from console by console

R1# show ip protocols | section Automatic

  Automatic network summarization is not in effect

R1#

This command has no effect when using RIPv1. When automatic summarization has been disabled, RIPv2 no longer summarizes networks to their classful address at boundary routers. RIPv2 now includes all subnets and their appropriate masks in its routing updates. The show ip protocols output now states that automatic network summarization is not in effect.

Configuring Passive Interfaces (3.3.1.6)

By default, RIP updates are forwarded out all RIP-enabled interfaces. However, RIP updates really only need to be sent out interfaces connecting to other RIP-enabled routers.

For instance, refer to the topology in Figure 3-22. RIP sends updates out of its Gigabit Ethernet 0/0 interface even though no RIP device exists on that LAN. R1 has no way of knowing this and, as a result, sends an update every 30 seconds. Sending out unneeded updates on a LAN impacts the network in three ways:

  • Wasted bandwidth: Bandwidth is used to transport unnecessary updates. Because RIP updates are either broadcasted or multicasted, switches also forward the updates out all ports.
  • Wasted resources: All devices on the LAN must process the update up to the transport layers, at which point the devices will discard the update.
  • Security risk: Advertising updates on a broadcast network is a security risk. RIP updates can be intercepted with packet sniffing software. Routing updates can be modified and sent back to the router, corrupting the routing table with false metrics that misdirect traffic.

To address these problems, an interface can be configured to stop sending routing updates. This is referred to as configuring a passive interface. Use the passive-interface router configuration command to prevent the transmission of routing updates through a router interface but still allow that network to be advertised to other routers. The command stops routing updates out the specified interface. However, the network that the specified interface belongs to is still advertised in routing updates that are sent out other interfaces.

There is no need for R1, R2, and R3 to forward RIP updates out of their LAN interfaces. The configuration in Figure 3-28 identifies the R1 Gigabit Ethernet 0/0 interface as passive.

Figure 3-28

Figure 3-28 Configuring and Verifying a Passive Interface on R1

The show ip protocols command is then used to verify that the Gigabit Ethernet interface was passive. Notice that the Gigabit Ethernet 0/0 interface is no longer listed as sending or receiving version 2 updates, but instead is now listed under the Passive Interface(s) section. Also notice that the network 192.168.1.0 is still listed under Routing for Networks, which means that this network is still included as a route entry in RIP updates that are sent to R2.

As an alternative, all interfaces can be made passive using the passive-interface default command. Interfaces that should not be passive can be re-enabled using the no passive-interface command.

Propagating a Default Route (3.3.1.7)

In the topology in Figure 3-29, R1 is single-homed to a service provider. Therefore, all that is required for R1 to reach the Internet is a default static route going out of the Serial 0/0/1 interface.

Figure 3-29

Figure 3-29 Propagating a Default Route on R1

Similar default static routes could be configured on R2 and R3, but it is much more scalable to enter it one time on the edge router R1 and then have R1 propagate it to all other routers using RIP. To provide Internet connectivity to all other networks in the RIP routing domain, the default static route needs to be advertised to all other routers that use the dynamic routing protocol.

To propagate a default route, the edge router must be configured with:

  • A default static route using the ip route 0.0.0.0 0.0.0.0 exit-intf next-hop-ip command.
  • The default-information originate router configuration command. This instructs R1 to originate default information, by propagating the static default route in RIP updates.

The example in Figure 3-30 configures a fully specified default static route to the service provider, and then the route is propagated by RIP. Notice that R1 now has a Gateway of Last Resort and default route installed in its routing table.

Figure 3-30

Figure 3-30 Configuring and Verifying a Default Route on R1

Configuring the RIPng Protocol (3.3.2)

In this section, you will learn how to configure, verify, and troubleshoot RIPng.

Advertising IPv6 Networks (3.3.2.1)

As with its IPv4 counterpart, RIPng is rarely used in modern networks. It is also useful as a foundation for understanding basic network routing. For this reason, this section provides a brief overview of how to configure basic RIPng.

Refer to the reference topology in Figure 3-31.

Figure 3-31

Figure 3-31 Enabling RIPng on the R1 Interfaces

In this scenario, all routers have been configured with basic management features and all interfaces identified in the reference topology are configured and enabled. There are no static routes configured and no routing protocols enabled; therefore, remote network access is currently impossible.

To enable an IPv6 router to forward IPv6 packets, ipv6 unicast-routing must be configured.

Unlike RIPv2, RIPng is enabled on an interface and not in router configuration mode. In fact, there is no network network-address command available in RIPng. Instead, use the ipv6 rip domain-name enable interface configuration command.

In the following output, IPv6 unicast routing is enabled and the Gigabit Ethernet 0/0 and Serial 0/0/0 interfaces are enabled for RIPng using the domain name RIP-AS:

R1(config)# ipv6 unicast-routing

R1(config)#

R1(config)# interface gigabitethernet 0/0

R1(config-if)# ipv6 rip RIP-AS enable

R1(config-if)# exit

R1(config)#

R1(config)# interface serial 0/0/0

R1(config-if)# ipv6 rip RIP-AS enable

R1(config-if)# no shutdown

R1(config-if)#

The process to propagate a default route in RIPng is identical to RIPv2 except that an IPv6 default static route must be specified. For example, assume that R1 had an Internet connection from a Serial 0/0/1 interface to IP address 2001:DB8:FEED:1::1/64. To propagate a default route, R1 would have to be configured with:

  • A default static route using the ipv6 route 0::/0 2001:DB8:FEED:1::1 global configuration command.
  • The ipv6 rip domain-name default-information originate interface configuration mode command. For example, the Serial 0/0/1 interface of R1 would have to be configured with the ipv6 rip RIP-AS default-information originate command. This would instruct R1 to be the source of the default route information and propagate the default static route in RIPng updates sent out of the RIPng-enabled interfaces.

Examining the RIPng Configuration (3.3.2.2)

In Figure 3-32, the show ipv6 protocols command does not provide the same amount of information as its IPv4 counterpart.

Figure 3-32

Figure 3-32 Verifying RIPng Settings on R1

However, the command does confirm the following parameters:

  1. That RIPng routing is configured and running on router R1.
  2. The interfaces configured with RIPng.

The show ipv6 route command displays the routes installed in the routing table as shown in Figure 3-33. The output confirms that R1 now knows about the highlighted RIPng networks.

Figure 3-33

Figure 3-33 Verifying Routes on R1

Notice that the R2 LAN is advertised as two hops away. This is because there is a difference in the way RIPv2 and RIPng calculate the hop counts. With RIPv2 (and RIPv1), the metric to the R2 LAN would be one hop. This is because the metric (hop count) that is displayed in the IPv4 routing table is the number of hops required to reach the remote network (counting the next-hop router as the first hop). In RIPng, the sending router already considers itself to be one hop away; therefore, R2 advertises its LAN with a metric of 1. When R1 receives the update, it adds another hop count of 1 to the metric. Therefore, R1 considers the R2 LAN to be two hops away. Similarly it considers the R3 LAN to be three hops away.

Appending the rip keyword to the command as shown in Figure 3-34 only lists RIPng networks.

Figure 3-34

Figure 3-34 Verifying RIPng Routes on R1

11. Link-State Dynamic Routing (3.4) | Next Section Previous Section

Cisco Press Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from Cisco Press and its family of brands. I can unsubscribe at any time.

Overview

Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about Cisco Press products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information

To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.

Surveys

Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites; develop new products and services; conduct educational research; and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.

Newsletters

If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@ciscopress.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information

Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.

Security

Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.

Children

This site is not directed to children under the age of 13.

Marketing

Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information

If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.

Choice/Opt-out

Users can always make an informed choice as to whether they should proceed with certain services offered by Cisco Press. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.ciscopress.com/u.aspx.

Sale of Personal Information

Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents

California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure

Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.

Links

This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact

Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice

We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020