Tải bản đầy đủ (.pdf) (100 trang)

Routing Protocols and Concepts – Chapter 1 potx

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (4.54 MB, 100 trang )

Introduction to Routing
and Packet Forwardin
g
g
Routing Protocols and Concepts – Chapter 1
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
ITE PC v4.0
Chapter 1
1
Objectives
 I
de
ntif
y

a
r
ou
t
e
r
as

a

co
m
pu
t
e
r with


a
n
OS

a
n
d

de y a ou e as a co pu e a OS a d
hardware designed for the routing process.

Demonstrate the ability to configure devices and
Demonstrate

the

ability

to

configure

devices

and

apply addresses.

Describe the structure of a routing table
Describe


the

structure

of

a

routing

table
.
 Describe how a router determines a path and
switches packets
switches

packets

ITE PC v4.0
Chapter 1
2
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Router as a Computer
 D
esc
ri
be
th
e


bas
i
c

pu
r
pose

o
f
a
r
ou
t
er
esc be e bas c pu pose o a ou e
-Computers that specialize in sending packets over the data
network.
They are responsible for interconnecting networks by selecting
the best path for a packet to travel and forwarding packets to
their destination
 Routers have many of the same hardware and software
com
p
onents that are found in other com
p
uters
pp
including:

–CPU
–RAM
–ROM
ITE PC v4.0
Chapter 1
3
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public

Operating System
Router as a Computer
 Router com
p
onents and their functions”
p
CPU - Executes operating system instructions
 such as system initialization, routing functions, and switching functions.

Random access memory (RAM)
RAM stores the instructions and data needed

Random

access

memory

(RAM)
-
RAM


stores

the

instructions

and

data

needed

to be executed by the CPU. RAM is used to store these components:
–Operating System: The Cisco IOS (Internetwork Operating System) is copied
into RAM durin
g
bootu
p
.
gp
–Running Configuration File: This is the configuration file that stores the
configuration commands that the router IOS is currently using.

IP Routin
g
Table: This file stores information about directl
y
connected and
g
y

remote networks. It is used to determine the best path to forward the packet.
–ARP Cache: This cache contains the IPv4 address to MAC address
mappings, similar to the ARP cache on a PC. The ARP cache is used on
hh LANi f h Eh i f
routers t
h
at
h
ave
LAN

i
nter
f
aces suc
h
as
E
t
h
ernet
i
nter
f
aces.
–Packet Buffer: Packets are temporarily stored in a buffer when received on an
interface or before they exit an interface.
ITE PC v4.0
Chapter 1
4

© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
RAM is volatile memory and loses its content when the router is powered down or
restarted.
Router as a Computer
 R
ou
t
e
r
co
m
po
n
e
nt
s

a
n
d
th
e
ir f
u
n
c
ti
o
n
s


ouecopoesadeucos
Read-only memory (ROM) - Holds diagnostic software used
when router is powered up. Stores the router’s bootstrap
p
ro
g
ram.
pg
–ROM is a form of permanent storage.
Cisco devices use ROM to store:
–The bootstrap instructions
–Basic diagnostic software

Scaled
-
down version of IOS

Scaled
-
down

version

of

IOS
ROM uses firmware, which is software that is embedded inside the
integrated circuit.


Firmware includes the software that does not normally need to
be modified or upgraded, such as the bootup instructions.
– ROM does not lose its contents when the router loses power
ITE PC v4.0
Chapter 1
5
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
or is restarted.
Rt C t
R
ou
t
er as a
C
ompu
t
e
r
 Router components and their functions”
Non-volatile RAM (NVRAM) - Stores startup configuration. This may include IP
addresses (Routing protocol Hostname of router)
addresses

(Routing

protocol
,
Hostname

of


router)
NVRAM (Nonvolatile RAM) does not lose its information when power is turned off. This is in
contrast to the most common forms of RAM, such as DRAM, that requires continual power to
maintain its information.

NVRAM is used by the Cisco IOS as permanent storage for the startup configuration file

NVRAM

is

used

by

the

Cisco

IOS

as

permanent

storage

for


the

startup

configuration

file
.
All configuration changes are stored in the running-config file in RAM, and with few
exceptions, are implemented immediately by the IOS.
To save those changes in case the router is restarted or loses power, the running-config
must be copied to NVRAM where it is stored as the startup
-
config file NVRAM retains its
must

be

copied

to

NVRAM
,
where

it

is


stored

as

the

startup
-
config

file
.
NVRAM

retains

its

contents even when the router reloads or is powered off.
Flash memory - Contains the operating system (Cisco IOS)
In most models of Cisco routers, the IOS is permanently stored in flash
memory and copied into RAM during the bootup process, where it is then
executed by the CPU.
Flash consists of SIMMs or PCMCIA cards, which can be upgraded to
increase the amount of flash memory
increase

the

amount


of

flash

memory
.
Interfaces - There exist multiple physical interfaces that are used to connect network.
Examples of interface types:
-Ethernet / fast Ethernet interfaces
ITE PC v4.0
Chapter 1
6
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
-Serial interfaces
-Management interfaces
Router as a Computer
 R
ou
t
e
r
co
m
po
n
e
nt
s
ou e co po e s

ITE PC v4.0
Chapter 1
7
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Internetwork Operating System
 The operating system software used in Cisco routers is known as Cisco
Internetwork Operating System (IOS)
Internetwork

Operating

System

(IOS)
.
– Cisco IOS is a multitasking operating system that is integrated with routing,
switching, internetworking, and telecommunications functions.

Although the Cisco IOS may appear to be the same on many routers,
Although

the

Cisco

IOS

may

appear


to

be

the

same

on

many

routers,

there are many different IOS images.
– An IOS image is a file that contains the entire IOS for that router. Cisco
creates many different types of IOS images, depending upon the model of
the router and the features within the IOS.
the

router

and

the

features

within


the

IOS.

– Typically the more features in the IOS, the larger the IOS image, and
therefore, the more flash and RAM that is required to store and load the IOS.
 Although some routers provide a graphical user interface (GUI), the
dli i t f (CLI)i h th d f
comman
d

li
ne
i
n
t
er
f
ace
(CLI)

i
s a muc
h
more common me
th
o
d
o

f

configuring Cisco routers.
– The CLI is used throughout this curriculum.

Upon bootup the startup
config file in NVRAM is copied into RAM and

Upon

bootup
,
the

startup
-
config

file

in

NVRAM

is

copied

into


RAM

and

stored as the running-config file.
– IOS executes the configuration commands in the running-config. Any
changes entered by the network administrator are stored in the running-
config and are immediately implemented by the IOS
ITE PC v4.0
Chapter 1
8
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
config

and

are

immediately

implemented

by

the

IOS
.
Overview
-

Managing Cisco IOS Software
(cont)
Overview

Managing

Cisco

IOS

Software
(cont)
ITE PC v4.0
Chapter 1
9
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Router as a Computer
 M
ajo
r
p
h
ases
t
o
th
e

ajo p ases o e
router boot-up process

Test router hardware
Power-On Self Test
(POST)
Execute bootstra
p
loade
r
p
Locate & load Cisco IOS
software
Locate IOS
-
Locate

IOS
-Load IOS
Locate & load startup
configuration file or enter
setup mode
-Bootstra
p

p
ro
g
ram looks
ITE PC v4.0
Chapter 1
10
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public

pp g
for configuration file
Stages of the router power-on boot sequence
ITE PC v4.0
Chapter 1
11
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Rt C t
R
ou
t
er as a
C
ompu
t
e
r
 Major phases to the router boot-up process
Step 1 and 2: Test router hardware
P
OSlfT t(POST)

P
ower-
O
n
S
e
lf


T
es
t

(POST)
–During this self-test, the router executes
diagnostics from ROM on several hardware
components including the CPU, RAM, and
NVRAM
•Execute bootstrap loader
–The main task of the bootstrap program is
to locate the Cisco IOS and load it into
RAM.

Note: At this point, if you have a console
connection to the router, you will begin to
see output on the screen.
Step 3 and 4: Locate & load Cisco IOS software
Locate IOS and Load IOS
-
Locate

IOS

and

Load

IOS
–The IOS is typically stored in flash

memory, but can also be stored in other
places such as a TFTP server.

If a full IOS ima
g
e can not be located
,
a
g,
scaled-down version of the IOS is copied
from ROM into RAM. This version of IOS is
used to help diagnose any problems and
can be used to load a complete version of
the IOS into RAM.
ITE PC v4.0
Chapter 1
12
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
–Note: A TFTP server is usually used as a
backup server for IOS but it can also be
used as a central point for storing and
loading the IOS.
Rt C t
R
ou
t
er as a
C
ompu
t

e
r
Step 5 and 6: Locate & load startup configuration file or enter setup
mode
-After the IOS is loaded, the bootstrap program searches for
the startup configuration file, known as startup-config, in
NVRAM. This parameters including:

interface addresses
interface

addresses
•routing information
•passwords
•an
y
other confi
g
urations
yg
–If the startup-config, is located in NVRAM, it is copied into
RAM as the running-config.
•The IOS loads the commands in the file, one line at a
time
time
.
–If the startup configuration file does not exist in NVRAM, the
router may search for a TFTP server.
• If the router detects that it has an active link to another
configured router, it sends a broadcast searching for a

configuration file across the active link. You will eventually
see message like the following one:

%Error opening tftp://255.255.255.255/network
-
confg
ITE PC v4.0
Chapter 1
13
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
%Error

opening

tftp://255.255.255.255/network
confg

(Timed out)
•%Error opening tftp://255.255.255.255/cisconet.cfg
(Timed out)
Router as a Computer
Router

as

a

Computer
 Locate & load startup configuration file or enter setup
mode

–Enter Setup Mode (Optional). If the startup
configuration file can not be located the router
configuration

file

can

not

be

located
,
the

router

prompts the user to enter setup mode.
•Setup mode is a series of questions prompting
the user for basic configuration information.
Setup mode is not intended to be used to enter
complex router configurations and it is not
complex

router

configurations
,
and


it

is

not

commonly used by network administrators.
–When booting a router that does not contain a
startup configuration file, you will see the following
question after the IOS has been loaded:
•Would you like to enter the initial configuration
dialog? [yes/no]: no
–Setup mode will not be used in this course
to configure the router. When prompted to
e
n
te
r
setup
m
ode,

a
lw
ays

a
n
s

w
e
r n
o
. If
you

e te setup ode, a ays a s e o you
answer yes and enter setup mode, you can
press Ctrl-C at any time to terminate the
setup process.
–When setup mode is not used, the IOS creates a
default running
-
config.
default

running
config.

•The default running-config is a basic
configuration file that includes the router
interfaces, management interfaces, and certain
default information.
Th d f lt i
fi d t t i
ITE PC v4.0
Chapter 1
14
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public


Th
e
d
e
f
au
lt
runn
i
ng-con
fi
g
d
oes no
t
con
t
a
i
n any
interface addresses, routing information,
passwords, or other specific configuration
information.
Router as a Computer
 Verify the router boot-up process:
show version
-The show version command is used
to view information about the router
during the bootup process.

Information includes:
Information

includes:
Image name & IOS version
IOS (tm) C2600 Software
(C2600
I
M) V i 12 2(28)
(C2600
-
I
-
M)
,
V
ers
i
on
12
.
2(28)
,
RELEASE SOFTWARE (fc5).
Bootstrap version stored in ROM
OS
R
O
M:
S

ystem Bootstrap,
Version 12.1(3r)T2, RELEASE
SOFTWARE (fc1)

Image file name & where it was

Image

file

name

&

where

it

was

loaded from
System image file is
"
flash:c2600
-
i
-
mz 122
-
28 bin

"
ITE PC v4.0
Chapter 1
15
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
flash:c2600
i
mz
.
122
28
.
bin
Router as a Computer
 Verify the router boot-up process:
show version
Platform model number
CPU

Amount of RAM

Amount

of

RAM
Some series of routers, like the
2600, use a fraction of DRAM as
packet memory. Packet memory is
df b ff i k t

use
d

f
or
b
u
ff
er
i
ng pac
k
e
t
s.
To determine the total amount of
DRAM on the router, add both
numbers. In this example, the Cisco
numbers.

In

this

example,

the

Cisco


2621 router has 60,416 KB
(kilobytes) of free DRAM used for
temporarily storing the Cisco IOS
and other s
y
stem
p
rocesses. The
yp
other 5,120 KB is dedicated for
packet memory. The sum of these
numbers is 65,536K, or 64
megabytes (MB) of total DRAM.
ITE PC v4.0
Chapter 1
16
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Router as a Computer
 Verify the router boot-up process:
show version
Number & type of interfaces
2 FastEthernet/IEEE 802.3
interface(s)
2 Low-speed serial(sync/async)
network interface(s)
Amount of NVRAM
32K bytes of non-volatile
configuration memory.
NVRAM is used to store the
startup

config file
startup
-
config

file
.
Amount of flash
16384K bytes of processor board
System flash (Read/Write)
System

flash

(Read/Write)
This is the amount of flash memory
on the router. Flash is used to
permanently store the Cisco IOS.
ITE PC v4.0
Chapter 1
17
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Router as a Computer
 Configuration register
show version
 Configuration register is 0x2102
–The last line of the show version
command displays the current
fi d l f th ft
con

fi
gure
d
va
l
ue o
f

th
e so
ft
ware
configuration register in
hexadecimal. If there is a second
value displayed in parentheses, it
denotes the configuration register
denotes

the

configuration

register

value that will be used during the
next reload.

The confi
g
uration re

g
ister has
lildi d
gg
severa
l
uses,
i
nc
l
u
di
ng passwor
d

recovery. The factory default setting
for the configuration register is
0x2102. This value indicates that
th t ill tt t t l d
th
e rou
t
er w
ill
a
tt
emp
t

t

o
l
oa
d
a
Cisco IOS software image from
flash memory and load the startup
configuration file from NVRAM.
ITE PC v4.0
Chapter 1
18
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public

Note: The configuration register is
discussed in more detail in a later
course.
Cfi ti it
C
on
fi
gura
ti
on reg
i
s
t
er
 The order in which the router looks for system
bootstrap depends on the boot field setting
in the

confi
g
uration re
g
ister.
gg
The default configuration register setting can be
changed with the global configuration mode
command config-register.
Use a hexadecimal number as the argument for this
command.
command.

 The configuration register is a 16-bit register in
NVRAM.
The lowest four bits of the configuration register form
the boot field.
To ensure that the upper 12 bits are not changed,
first retrieve the current values of the configuration
register using the show version command.
Then use the config-register command, changing
only the value of the last hexadecimal digit.
ITE PC v4.0
Chapter 1
19
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Configuration register (cont )
Configuration

register


(cont
.
)
 To enter the ROM monitor mode, set the configuration
register value to 0xnnn0,
where nnn represents the previous value of the non-boot field
di it
di
g
it
s.
This value sets the boot field bits to 0000 binary.
From ROM monitor, boot the operating system manually by
using the b command at the ROM monitor prompt.

To configure the system to boot automatically from ROM

To

configure

the

system

to

boot


automatically

from

ROM
,
set the configuration register to 0xnnn1,
This value sets the boot field bits to 0001 binary.
 To configure the system to use the boot system
commands in NVRAM set the configuration register to
commands

in

NVRAM
,
set

the

configuration

register

to

any value from 0xnnn2 to 0xnnnF,
These values set the boot field bits to a value between 0010
and 1111 binary.
Using boot system commands in NVRAM is the default.

Check Configuration Register value (NVRAM)
0 = ROM Monitor mode
1
=
ROM IOS
ITE PC v4.0
Chapter 1
20
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
1

ROM

IOS
2 - 15 = Boot system from Flash
How a Cisco device locates and loads IOS
The config-register can be Downloaded from:
http:// lilligren com/cisco/do nloads htm
 Demo
config-register
http://
www.
lilligren
.
com/cisco/do
w
nloads
.
htm
ITE PC v4.0

Chapter 1
21
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Configuration register: 0, 1, and 2 and above
ITE PC v4.0
Chapter 1
22
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Configuration register: 2102 and 2142
Configuration

register:

2102

and

2142

ITE PC v4.0
Chapter 1
23
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Configuration register
Configuration

register

Router(config)#config-register value
1

2
3
ITE PC v4.0
Chapter 1
24
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
Stages of the router power
-
on boot sequence
Stages

of

the

router

power
-
on

boot

sequence

1. ROM
1. POST
2. Bootstrap code executed
1, 2
3. Check Configuration Register value (NVRAM)

0 = ROM Monitor mode
1 = ROM IOS
2 - 15 = Boot system from flash
3
4
2. Check for IOS boot system commands in startup-config file (NVRAM)
If boot system commands in startup-config
a. Run boot system commands in order they appear in startup-config to locate the IOS
4
b If boot system commands fail, use default fallback sequence to locate the IOS (Flash, TFTP, ROM)
3. Locate and load IOS, Default fallback sequence: No IOS boot system commands in startup-config
a. Flash (sequential)
b. TFTP server (netboot) - The router uses the configuration register value to form a filename from which to boot a default system image stored
on a network server.
c. ROM (partial IOS) or keep retrying TFTP depending upon router model
- If no IOS located, get partial IOS version from ROM
4. Locate and load startup-config
a. If startup-config found, copy to running-config
b. If startup-config not found, prompt for setup-mode
c If setup
mode bypassed create a

skeleton

default running
config (no startup
config)
ITE PC v4.0
Chapter 1
25

© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public
c
.
If

setup
-
mode

bypassed
,
create

a

skeleton

default

running
-
config

(no

startup
-
config)

×