Вы находитесь на странице: 1из 56

Chapter 2-Static Routing

CCNA Exploration 4.0

Objectives

Define the general role a router plays in networks. Describe the directly connected networks, different router interfaces Examine directly connected networks in the routing table and use the CDP protocol Describe static routes with exit interfaces Describe summary and default route Examine how packets get forwarded when using static routes Identify how to manage and troubleshoot static routes

Hc vin mng Bach Khoa - Website: www.bkacad.com

Role of the Router

The router is a special-purpose computer that plays a key role in the operation of any data network. Routers are primarily responsible for interconnecting networks by: Determining the best path to send packets. Forwarding packets toward their destination.

Hc vin mng Bach Khoa - Website: www.bkacad.com

Introducing the topology

Topology Lab Three 1800 series routers connected via WAN links. Each router connected to a LAN represented by a switch and a PC.

Hc vin mng Bach Khoa - Website: www.bkacad.com

Cable for LAN/WAN interfaces

Hc vin mng Bach Khoa - Website: www.bkacad.com

Examining Router Interfaces


Examining Router Interfaces
show ip route command used to view routing table show interfaces command used to show status of an interface show ip Interface brief command used to show a portion of the interface information show running-config command used to show configuration file in RAM

Hc vin mng Bach Khoa - Website: www.bkacad.com

Configuring an Ethernet Interface


Configuring an Ethernet interface
By default all serial and Ethernet interfaces are admintrative down. To enable an interface use the no shutdown command.

Hc vin mng Bach Khoa - Website: www.bkacad.com

Configuring an Ethernet Interface

Verifying Ethernet interface Show interfaces for fastEthernet 0/0 command used to show status of fast Ethernet port. Show ip interface brief. Show running-config. Ethernet interfaces participate in ARP

Hc vin mng Bach Khoa - Website: www.bkacad.com

Logging Synchronous Command

In order to keep the unsolicited output separate from your input, enter line configuration mode for the consoled port and add the logging synchronous command.

Hc vin mng Bach Khoa - Website: www.bkacad.com

Configuring a Serial Interfaces


Configuring a Serial interface
Enter interface configuration mode Enter in the ip address and subnet mask Enter in the clock rate(DCE) and no shut down command

Example:

R1(config)#interface serial 0/0 R1(config-if)#ip address 172.16.2.1 255.255.255.0 R1(config-if)#clock rate 64000 R1(config-if)#no shutdown

Hc vin mng Bach Khoa - Website: www.bkacad.com

10

Verifying Changes to the Routing Table

The routing table consists of a list of "known" network addresses these addresses that are directly connected, configured statically, and learned dynamically.

Hc vin mng Bach Khoa - Website: www.bkacad.com

11

Verifying Changes to the Routing Table

Observing Routes as They are Added to the Routing Table debug ip routing command will let us see any changes that the router performs when adding or removing routes.

Hc vin mng Bach Khoa - Website: www.bkacad.com

12

Devices on Directly Connected Networks

When a router only has its interfaces configured, and the routing table contains the directly connected networks but no other routes, only devices on those directly connected networks are reachable.

Hc vin mng Bach Khoa - Website: www.bkacad.com

13

Devices on Directly Connected Networks

Hc vin mng Bach Khoa - Website: www.bkacad.com

14

Cisco Discovery Protocol (CDP)


Network discovery with CDP CDP is an information-gathering tool used by network administrators to get information about directly connected Cisco devices. CDP is a proprietary tool that enables you to access a summary of protocol and address information about Cisco devices that are directly connected. These advertisements contain information such as the types of devices that are connected, the router interfaces they are connected to, the interfaces used to make the connections, and the model numbers of the devices. Concept of neighbors 2 types of neighbors Layer 3 neighbors. Layer 2 neighbors.

Hc vin mng Bach Khoa - Website: www.bkacad.com

15

Cisco Discovery Protocol (CDP)


CDP Operation CDP runs at the Data Link layer connecting the physical media to the upper-layer protocols (ULPs). Cisco network devices, such as routers that support different Network layer protocols (for example, IP and Novell IPX), can learn about each other CDP provides the following information about each CDP neighbor device: Device identifiers Address list Port identifier Capabilities list Platform

Hc vin mng Bach Khoa - Website: www.bkacad.com

16

Default Setting

Feature

Default Setting

CDP global state


CDP interface state CDP holdtime (packet holdtime in seconds) CDP timer (packets sent every x seconds)

Enabled
Enabled 180 60

Hc vin mng Bach Khoa - Website: www.bkacad.com

17

Using CDP for Network Discovery

The information gathered by the CDP protocol can be examined with the show cdp neighbors command.

Hc vin mng Bach Khoa - Website: www.bkacad.com

18

Using CDP for Network Discovery


Field Device ID Definition The name of the neighbor device and either the MAC address or the serial number of this device. The protocol being used by the connectivity media. The remaining amount of time (in seconds) the current device will hold the CDP advertisement from a sending router before discarding it.

Local Intrfce Holdtme

Hc vin mng Bach Khoa - Website: www.bkacad.com

19

Using CDP for Network Discovery


Capability (Capability Codes) Capability (type of routing device) of the listed neighboring device. The capability types that can be discovered are: RRouter TTransparent bridge BSource-routing bridge SSwitch HHost I device is using IGMP rRepeater

Platform Port ID

The product number of the device. The protocol and port number of the device.
Hc vin mng Bach Khoa - Website: www.bkacad.com 20

Using CDP for Network Discovery

To disable CDP on a specific interface after it has been enabled, use the no CDP enable command in interface configuration mode.

Hc vin mng Bach Khoa - Website: www.bkacad.com

21

CDP Commands

Hc vin mng Bach Khoa - Website: www.bkacad.com

22

CDP Commands

Hc vin mng Bach Khoa - Website: www.bkacad.com

23

CDP Commands

Hc vin mng Bach Khoa - Website: www.bkacad.com

24

CDP Commands

Hc vin mng Bach Khoa - Website: www.bkacad.com

25

STATIC ROUTING

Hc vin mng Bach Khoa - Website: www.bkacad.com

26

Purpose and Command Syntax of ip route



Static routes are commonly used when routing from a network to a stub network. A stub network is a network accessed by a single route.

Hc vin mng Bach Khoa - Website: www.bkacad.com

27

ip route command
RTR(config)# ip route prefix mask {address | interface} [distance] [tag tag] [permanent]

prefix mask address


that network.

IP route prefix for the destination. Prefix mask for the destination. IP address of the next hop that can be used to reach Network interface to use (exit-interface) (Optional) An administrative distance.

interface distance tag tag

(Optional) Tag value that can be used as a "match" value for controlling redistribution via route maps. (CCNP Advanced Routing)

Permanent (Optional) Specifies that the route will not be removed,


even if the interface shuts down. (CCNP Advanced Routing)

Hc vin mng Cisco Bch Khoa - Website: www.ciscobachkhoa.com

28

Configuring Static Routes

Installing a Static Route in the Routing Table

Hc vin mng Bach Khoa - Website: www.bkacad.com

29

Configuring Static Routes


Configuring Routes to Two More Remote Networks

Hc vin mng Bach Khoa - Website: www.bkacad.com

30

Routing Table Principles and Static Routes

Hc vin mng Bach Khoa - Website: www.bkacad.com

31

Routing Table Principles and Static Routes

Applying the Principles

Hc vin mng Bach Khoa - Website: www.bkacad.com

32

Resolving to an Exit Interface

Hc vin mng Bach Khoa - Website: www.bkacad.com

33

Resolving to an Exit Interface

Exit Interface is Down

Hc vin mng Bach Khoa - Website: www.bkacad.com

34

Configuring a Static Route with an Exit Interface

Static routes can be configured with an exit interface, which allows the routing table to resolve the exit interface in a single search instead of two searches.

Hc vin mng Bach Khoa - Website: www.bkacad.com

35

ip route command
RTR(config)# ip route prefix mask {address | interface} [distance] [tag tag] [permanent]

prefix mask address


that network.

IP route prefix for the destination. Prefix mask for the destination. IP address of the next hop that can be used to reach Network interface to use (exit-interface) (Optional) An administrative distance.

interface distance tag tag

(Optional) Tag value that can be used as a "match" value for controlling redistribution via route maps. (CCNP Advanced Routing)

Permanent (Optional) Specifies that the route will not be removed,


even if the interface shuts down. (CCNP Advanced Routing)

Hc vin mng Cisco Bch Khoa - Website: www.ciscobachkhoa.com

36

Configuring a Static Route with an Exit Interface

Static Route and an Exit Interface

Hc vin mng Bach Khoa - Website: www.bkacad.com

37

Modifying Static Routes


There are times when a previously configured static route needs to be
modified: The destination network no longer exists, and therefore the static route should be deleted. There is a change in the topology, and either the intermediate address or the exit interface has to be changed.

Hc vin mng Bach Khoa - Website: www.bkacad.com

38

Verifying the Static Route Configuration


Verifying the Static Route Configuration
Use the following commands Step 1 show running-config. Step 2 verify static route has been entered correctly. Step 3 show ip route. Step 4 verify route was configured in routing table. Step 5 issue ping command to verify packets can reach destination and that Return path is working.

Hc vin mng Bach Khoa - Website: www.bkacad.com

39

Static Routes with Ethernet Interfaces


Ethernet interfaces and ARP. If a static route is configured on an
Ethernet link If the packet is sent to the next-hop router then the destination MAC address will be the address of the next hops Ethernet interface This is found by the router consulting the ARP table. If an entry isnt found then an ARP request will be sent out

Hc vin mng Bach Khoa - Website: www.bkacad.com

40

Static Routes with Ethernet Interfaces


Static routes and Ethernet exit interfaces With Ethernet networks, there may be many different devices sharing the same multi-access network, including hosts and even multiple routers. Thefore, router does not know the next-hop IP address and therefore it cannot determine the destination MAC address for the Ethernet frame.

Hc vin mng Bach Khoa - Website: www.bkacad.com

41

Summary Static Routes


Route Summarization Summarizing Routes to Reduce the Size of the Routing Table Multiple static routes can be summarized into a single static route if: The destination networks can be summarized into a single network address, and The multiple static routes all use the same exit-interface or nexthop IP address

Hc vin mng Bach Khoa - Website: www.bkacad.com

42

Summary Static Routes

Configuring a Summary Route

Configuring a summary route

Step 1: Delete the current static route


Step 2: Configure the summary static route Step 3: Verify the new static route

Hc vin mng Bach Khoa - Website: www.bkacad.com

43

Default Static Route


A default static route is a route that will match all packets. Default static
routes are used: When no other routes in the routing table match the packet's destination IP address. In other words, when a more specific match does not exist. A common use is when connecting a company's edge router to the ISP network. When a router has only one other router to which it is connected. This condition is known as a stub router. Using command: ip route 0.0.0.0 0.0.0.0 {exit Interface, IP NextHop}

Hc vin mng Bach Khoa - Website: www.bkacad.com

44

Default Static Route

Verifying a Default Static Route

Hc vin mng Bach Khoa - Website: www.bkacad.com

45

Static Routes and Packet Forwarding

Static Routes and Packet Forwarding

Hc vin mng Bach Khoa - Website: www.bkacad.com

46

Static Routes and Packet Forwarding

Hc vin mng Bach Khoa - Website: www.bkacad.com

47

Static Routes and Packet Forwarding

Hc vin mng Bach Khoa - Website: www.bkacad.com

48

Static Routes and Packet Forwarding

Hc vin mng Bach Khoa - Website: www.bkacad.com

49

Static Routes and Packet Forwarding

Hc vin mng Bach Khoa - Website: www.bkacad.com

50

Static Routes and Packet Forwarding

Hc vin mng Bach Khoa - Website: www.bkacad.com

51

Static Routes and Packet Forwarding

Hc vin mng Bach Khoa - Website: www.bkacad.com

52

Troubleshooting a Missing Route


Troubleshooting a Missing Route Tools that can be used to isolate routing problems include:
Ping tests end to end connectivity Traceroute used to discover all of the hops (routers) along the path between 2 points Show IP route used to display routing table & ascertain forwarding process Show ip interface brief- used to show status of router interfaces Show cdp neighbors detail used to gather configuration information about directly connected neighbors

Hc vin mng Bach Khoa - Website: www.bkacad.com

53

Summary

Routers Operate at layer 3 Functions include best path selection & forwarding packets Connecting Networks WANs
Serial cables are connected to router serial ports. In the lab environment clock rates must be configured for DCE

LANs

Straight through cables or cross over cables are used to connect to fastethernet port. (The type of cable used depends on what devices are being connected)

Cisco Discovery Protocol A layer 2 proprietary protocol Used to discover information about directly connected Cisco devices
Hc vin mng Bach Khoa - Website: www.bkacad.com 54

Summary

Static Routes
This is a manually configured path that specifies how the router will get to a certain point using a certain path. This is several static routes that have been condensed into a single static route. It is the route packets use if there is no other possible match for their destination in the routing table. Zinins 3 routing principles describe how packets are forwarded Ping Traceroute Show IP route Show ip interface brief Show cdp neighbors detail
Hc vin mng Bach Khoa - Website: www.bkacad.com 55

Summary static routes



Default route

Forwarding of packets when static route are used

Troubleshooting static routes may require some of the


following commands:

Hc vin mng Bach Khoa - Website: www.bkacad.com

56

Вам также может понравиться