• 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
Trang 1Chapter 2-Static Routing
CCNA Exploration 4.0
Trang 2• 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
Trang 3Role 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.
Trang 4Introducing 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.
Trang 5Cable for LAN/WAN interfaces
Trang 6Examining 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
Trang 7Configuring 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
Trang 8Configuring 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
Trang 9Logging 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.
Trang 10Configuring 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
Trang 11Verifying 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
Trang 12Verifying 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.
Trang 13Devices 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
Trang 14Devices on Directly Connected Networks
Trang 15Cisco 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
Trang 16Cisco Discovery Protocol (CDP)
• CDP provides the following information about each CDP neighbor
Trang 17Default Setting
CDP global state Enabled
CDP interface state Enabled
CDP holdtime (packet holdtime in
seconds)
180 CDP timer (packets sent every x seconds) 60
Trang 18Using CDP for Network Discovery
• The information gathered by the CDP protocol can be examined with the show cdp neighbors command
Trang 19Using CDP for Network Discovery
Device ID The name of the neighbor device and either the
MAC address or the serial number of this device
Local Intrfce The protocol being used by the connectivity
media
Holdtme The remaining amount of time (in seconds) the
current device will hold the CDP advertisement from a sending router before discarding it
Trang 20Using CDP for Network Discovery
H—Host I— device is using IGMP r—Repeater
Platform The product number of the device
Trang 21Using CDP for Network Discovery
To disable CDP on a specific interface after it has been enabled, use the no CDP enable
command in interface
Trang 22CDP Commands
Trang 23CDP Commands
Trang 24CDP Commands
Trang 25CDP Commands
Trang 26STATIC ROUTING
Trang 27Purpose 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
Trang 28ip route command
RTR(config)# ip route prefix mask {address |
interface} [distance] [tag tag] [permanent]
• prefix IP route prefix for the destination
• mask Prefix mask for the destination
• address IP address of the ―next hop‖ that can be used to reach
that network
• interface Network interface to use (exit-interface)
• distance (Optional) An administrative 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)
Trang 29Configuring Static Routes
• Installing a Static Route in the Routing Table
Trang 30Configuring Static Routes
Configuring Routes to Two More Remote Networks
Trang 31Routing Table Principles and Static Routes
Trang 32Routing Table Principles and Static Routes
• Applying the Principles
Trang 33Resolving to an Exit Interface
Trang 34Resolving to an Exit Interface
• Exit Interface is Down
Trang 35Configuring 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
Trang 36ip route command
RTR(config)# ip route prefix mask {address |
interface} [distance] [tag tag] [permanent]
• prefix IP route prefix for the destination
• mask Prefix mask for the destination
• address IP address of the ―next hop‖ that can be used to reach
that network
• interface Network interface to use (exit-interface)
• distance (Optional) An administrative 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)
Trang 37Configuring a Static Route with an Exit Interface
• Static Route and an Exit Interface
Trang 38Modifying 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
Trang 39Verifying 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
Trang 40Static 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 hop’s Ethernet interface
– This is found by the router consulting the ARP table If an entry
isn’t found then an ARP request will be sent out
Trang 41Static 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
Trang 42Summary 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
next-hop IP address
Trang 43Summary Static Routes
• Configuring a Summary Route
Configuring a summary route
Step 1: Delete the current static routeStep 2: Configure the summary static routeStep 3: Verify the new static route
Trang 44Default 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}
Trang 45Default Static Route
• Verifying a Default Static Route
Trang 46Static Routes and Packet Forwarding
• Static Routes and Packet Forwarding
Trang 47Static Routes and Packet Forwarding
Trang 48Static Routes and Packet Forwarding
Trang 49Static Routes and Packet Forwarding
Trang 50Static Routes and Packet Forwarding
Trang 51Static Routes and Packet Forwarding
Trang 52Static Routes and Packet Forwarding
Trang 53Troubleshooting 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
Trang 54• Serial cables are connected to router serial ports
• In the lab environment clock rates must be configured for DCE
• 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
Trang 55• Static Routes
– This is a manually configured path that specifies how the
router will get to a certain point using a certain path
• Summary static routes
– This is several static routes that have been condensed into a
single static route
• Default route
– It is the route packets use if there is no other possible match
for their destination in the routing table
• Forwarding of packets when static route are used
– Zinin’s 3 routing principles describe how packets are