1. Trang chủ
  2. » Công Nghệ Thông Tin

Tài liệu học CCNA kỳ 2 mod3 ConfiguringARouter

22 307 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 22
Dung lượng 618,21 KB

Các công cụ chuyển đổi và chỉnh sửa cho tài liệu này

Nội dung

NIIT-ICT Hanoi info@niithanoi.vn 5Configuring router passwords Not recommended, clear text Routerconfig#enable secret Use this command instead, password is encryped Encrypts the passwor

Trang 1

Module 3 – Configuring a Router

Overview

Students completing this module should be able to:

• Set passwords

Trang 2

NIIT-ICT Hanoi info@niithanoi.vn 3

CLI command modes

Router#configure terminal

Router(config)#

Configuring a router name

Router#config t

Router(config)#hostname Tokyo

Tokyo(config)#

Trang 3

NIIT-ICT Hanoi info@niithanoi.vn 5

Configuring router passwords

Not recommended, clear text

Router(config)#enable secret <password>

Use this command instead, password is encryped

Encrypts the passwords above, but…

WARNING

service password-encryption uses a Cisco Level 7

encryption which is very easy to decrypt.

• For the GetPass! software www.boson.com

However, the enable secret <password> uses a stronger

Trang 4

NIIT-ICT Hanoi info@niithanoi.vn 7

Doesn’t work for enable secret!

exit end Using exit, end and Control-Z

Trang 5

NIIT-ICT Hanoi info@niithanoi.vn 9

access-list Add an access list entry

alias Create command alias

Must be in privileged mode

Using exit, end and Control-Z

Router(config)# router protocol

Trang 6

NIIT-ICT Hanoi info@niithanoi.vn 11

Examining the show commands

show interfaces – Displays all the statistics for all the interfaces on the

router To view the statistics for a specific interface, enter the show

interfaces command followed by the specific interface and port number

show controllers serial – Displays information-specific to the interface

hardware

show clock – Shows the time set in the router

show hosts – Displays a cached list of host names and addresses

show users – Displays all users who are connected to the router

show history – Displays a history of commands that have been entered

show flash – Displays information about flash memory and what IOS files

are stored there

show version – Displays information about the router and the IOS that is

running in RAM

show ARP – Displays the ARP table of the router

show protocol – Displays the global and interface specific status of any

configured Layer 3 protocols

show startup-configuration – Displays the saved configuration located

in NVRAM

show running-configuration – Displays the configuration currently

running in RAM

Router>show interface ethernet 0

Ethernet0 is administratively down, line protocol is down , using hub 0

Hardware is Lance, address is 0010.7b3a.cf84 (bia 0010.7b3a.cf84)

MTU 1500 bytes, BW 10000 Kbit, DLY 1000 usec, rely 255/255, load 1/255

Encapsulation ARPA, loopback not set, keepalive set (10 sec)

ARP type: ARPA, ARP Timeout 04:00:00

Last input never, output 01:05:35, output hang never

Last clearing of "show interface" counters never

Queueing strategy: fifo

Output queue 0/40, 0 drops; input queue 0/75, 0 drops

5 minute input rate 0 bits/sec, 0 packets/sec

5 minute output rate 0 bits/sec, 0 packets/sec

0 packets input, 0 bytes, 0 no buffer

Received 0 broadcasts, 0 runts, 0 giants, 0 throttles

0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort

0 input packets with dribble condition detected

63 packets output, 11676 bytes, 0 underruns

0 output errors, 0 collisions, 1 interface resets

0 babbles, 0 late collision, 0 deferred

0 lost carrier, 0 no carrier

0 output buffer failures, 0 output buffers swapped out

Router>

Status MAC Address

Routing metric information (later)

Data link

encapsulation

(Ethernet-II)

ARP cache entries timer

Trang 7

NIIT-ICT Hanoi info@niithanoi.vn 13

Where is the MAC Address?

Router>show interface serial 0

Serial0 is administratively down, line protocol is down

Hardware is HD64570

MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, rely 255/255, load 1/255

Encapsulation HDLC, loopback not set, keepalive set (10 sec)

Last input never, output never, output hang never

Last clearing of "show interface" counters never

Queueing strategy: fifo

Output queue 0/40, 0 drops; input queue 0/75, 0 drops

5 minute input rate 0 bits/sec, 0 packets/sec

5 minute output rate 0 bits/sec, 0 packets/sec

0 packets input, 0 bytes, 0 no buffer

Received 0 broadcasts, 0 runts, 0 giants, 0 throttles

0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort

28 packets output, 9576 bytes, 0 underruns

0 output errors, 0 collisions, 17 interface resets

0 output buffer failures, 0 output buffers swapped out

0 carrier transitions

DCD=down DSR=down DTR=down RTS=down CTS=down

Router>

Examining the show commands

commands.

Trang 8

NIIT-ICT Hanoi info@niithanoi.vn 15

Configuring a serial interface

Router(config)#interface serial 0/0

Router(config-if)#ip address <ip address> <netmask>

Configuring an IP Address on an interface…

show ip interface command

ends are properly configured (mostly) and a the no

shutdown command is used

router’s configuration.

Router# show ip interface brief

Interface IP-Address OK? Method Status Protocol

Ethernet0 131.108.1.11 YES manual up up

Serial0 198.135.2.49 YES manual administratively down down

What is wrong here? The administrator has either done a

“shutdown” on the interface or has forgotten to do a “no shutdown”.

Trang 9

NIIT-ICT Hanoi info@niithanoi.vn 17

Lab

Real world

• On serial links that are directly interconnected, as in a lab environment,

one side must be considered a DCE and provide a clocking signal.

The clock is enabled and speed is specified with the clock rate

RouterA

DTE cable

Configuring a serial interface

Trang 10

NIIT-ICT Hanoi info@niithanoi.vn 19

How can you tell which end is the DTE and which end is the DCE?

„ Look at the label on the cable.

„ Look at the connecter between the two cables - The DTE cable will

always be male and the DCE cable will always be female.

Configuring a serial interface

RouterA#show controllers serial 0

HD unit 0, idb = 0xECA4C, driver structure at 0xF1EC8

buffer size 1524 HD unit 0, V.35 DTE cable

cpb = 0x62, eda = 0x403C, cda = 0x4050

RX ring with 16 entries at 0x624000

00 bd_ptr=0x4000 pak=0x0F5704 ds=0x62FFB8 status=80 pak_size=22

RouterB#show controllers serial 0

buffer size 1524 HD unit 0, V.35 DCE cable, clockrate 64000

cpb = 0x62, eda = 0x408C, cda = 0x40A0

RX ring with 16 entries at 0x624000

00 bd_ptr=0x4000 pak=0x0F2F04 ds=0x627908 status=80 pak_size=22

RouterB DCE cable

RouterA

DTE cable

How can you tell which end is the DTE and which end is the DCE?

„ Use the show controllers command!

„ It will also tell you the type of cable, in our labs we will be using a V.35

cable.

This is one of few commands where there must be a space between the interface type and the port

Configuring a serial interface

Trang 11

NIIT-ICT Hanoi info@niithanoi.vn 21

running-config

IOS (running)

startup-config IOS

ios (partial) Bootup program

Executing adds, moves, and changes

service timestamps debug uptime

service timestamps log uptime

Default running-config file, created in RAM

Executing adds, moves, and changes

Trang 12

NIIT-ICT Hanoi info@niithanoi.vn 23

The running-config

• The configuration file contains global, process, and interface information that directly affects the

operation of the router and its interface ports

All changes to the router are made to the running-config file and take affect immediately on the

router (with just a couple of exceptions)

service timestamps debug uptime

service timestamps log uptime

Executing adds, moves, and changes

startup-config

RAM

running-config

During bootup

• Changes to the router are automatically put in the running-config file

• If the router loses power or reboots, everything in RAM is lost including the

running-config file

• To make sure the changes to the router’s configuration remain saved, you must copy

the running-config from RAM into the startup-config into NVRAM:

Router# copy running-config startup-config

Router# copy running-config startup-config

copy running-config startup-config

Trang 13

NIIT-ICT Hanoi info@niithanoi.vn 25

Router#copy running-config startup-config

Destination filename [startup-config]?

Building configuration

Router#show startup-config

!

version 12.0

service timestamps debug uptime

service timestamps log uptime

copy running-config startup-config

show startup-config show running-config

1Displaying the config files

Trang 14

NIIT-ICT Hanoi info@niithanoi.vn 27

Configuring an Ethernet Interface

Trang 15

NIIT-ICT Hanoi info@niithanoi.vn 29

Gateway#show interface ethernet 0

Ethernet0 is administratively down, line protocol is down

Hardware is Lance, address is 0000.0c34.9ebb (bia 0000.0c34.9ebb)

Description: LAN interface for Marketing

MTU 1500 bytes, BW 10000 Kbit, DLY 1000 usec, rely 252/255, load 1/255

Encapsulation ARPA, loopback not set, keepalive set (10 sec)

ARP type: ARPA, ARP Timeout 04:00:00

<text omitted>

Gateway#copy run start

Destination filename [startup-config]?

Trang 16

NIIT-ICT Hanoi info@niithanoi.vn 31

Login banners and Configuring

message-of-the-day (MOTD)

Wording is not the same, but you get the idea.

Delimiter always shows as “^C”

MOTD (Message Of The Day) Prompt changes

Login banners and Configuring

message-of-the-day (MOTD)

Trang 17

NIIT-ICT Hanoi info@niithanoi.vn 33

Host name resolution

Router# traceroute Capetown

• The Cisco IOS software maintains a cache of host name-to-address mappings

for use by EXEC commands

• This cache speeds up the process of converting names to addresses

• Host names, unlike DNS names, are significant only on the router on which

they are configured (DNS is also an option – later)

Host name resolution

• This does not make the router a DNS (Domain Name Server).

• This command does not turn your router into a DNS server.

• This command does not effect packets entering your router to be

routed.

• This only affects the IOS commands entered at the router prompt.

• Multiple ip addresses can be entered in case one interface is down.

• It is usually a good idea to use the same list of names on all your router

configs

Router(config)# ip host SantaCruz 172.16.32.1 192.168.53.1

Configuring Multiple IP Addresses

Trang 18

NIIT-ICT Hanoi info@niithanoi.vn 35

Configuring host tables

• If you are not using the services of a DNS server, it is best to disable this process.

• DNS (Domain Name Service) is enabled by default with a server address of

255.255.255.255, which is a local broadcast

• If enabled, with no DNS server on the network, may cause a slight, but irritable

delay when making typing mistakes.

Router(config)# ip domain-lookup

Router#wreh

Translating "wreh" domain server (255.255.255.255) (Takes a few seconds)

Translating "wreh" domain server (255.255.255.255) (Takes a few seconds)

Trang 19

NIIT-ICT Hanoi info@niithanoi.vn 37

Configuration backup and documentation

event of a problem

TFTP server, or on a disk stored in a safe place

Copying, editing, and pasting configurations

• A TFTP server will allow image and configuration uploads and

downloads over the network

• The TFTP server can be another router, or it can be a host system

Trang 20

NIIT-ICT Hanoi info@niithanoi.vn 39

• The TFTP host can be any system that has TFTP software loaded and

operating and able to receive files from the TCP/IP network

Copying, editing, and pasting configurations

RAM

IOS (running)

running-config startup-config IOS

copy startup-config tftp copy tftp startup-config

copy running-config tftp copy tftp running-config

copy flash tftp copy tftp flash

Copying, editing, and pasting configurations

Trang 21

NIIT-ICT Hanoi info@niithanoi.vn 41

Copying, editing, and pasting configurations

• Troubleshooting: Be sure you can ping the TFTP server.

• When using Windows, the TFTP server software must be running.

• The copy can be performed from the console port or from a telnet session.

Router# copy flash tftp

TFTP Software and Servers

Trang 22

NIIT-ICT Hanoi info@niithanoi.vn 43

Summary (1/2)

The router has several modes:

The command-line interface may be used to make changes

any organization maintaining an efficient network

help network administrators understand and troubleshoot

their networks

with information upon login to the router

allow the router to quickly convert names to addresses

important to keep a network operating smoothly

Ngày đăng: 05/07/2015, 22:39