Chapter 5
Managing Your Network Environment © 1999, Cisco Systems, Inc.
51
Objectives Upon completion of this chapter, you will be able to perform the following tasks: • Gather information about neighbor devices • Gather information about remote devices • Create a simple network diagram to document the network • Determine the location from which a configuration and IOS image will be loaded © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—52
Cisco Discovery Protocol UpperLayer Entry Addresses
TCP/IP
Cisco Proprietary DataLink Protocol
CDP discovers and shows information about directly connected Cisco devices
Media Supporting SNAP
LANs
Novell IPX
Frame Relay
AppleTalk
ATM
Others
Others
• A proprietary utility that gives you a summary of directly connected switches, routers, and other Cisco devices • CDP discovers neighbor devices regardless of which protocol suite they are running • Physical media must support the Subnetwork Access Protocol (SNAP) encapsulation © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—53
Discovering Neighbors with CDP Runs on routers with Cisco IOS 10.3 or later and Cisco switches and hubs Summary information includes: • Device identifiers • Address list
CDP
CDP
CDP
• Port identifier
show cdp
• Capabilities list • Platform © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—54
Using CDP SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
10.1.1.1
10.1.1.2
RouterB 10.2.2.1
SwitchB 10.2.2.2
outerA#sh cdp ? entry Information for specific neighbor entry interface CDP interface status and configuration neighbors CDP neighbor entries traffic CDP statistics outerA(config)#no cdp run outerA(config)#interface serial0 outerA(config-if)#no cdp enable
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—55
Using the show cdp neighbor Command SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
10.1.1.1
10.1.1.2
RouterB
SwitchB
10.2.2.1
10.2.2.2
RouterA#sh cdp neighbors Capability Codes: R - Router, T - Trans Bridge, B - Source Route Bridge S - Switch, H - Host, I - IGMP, r - Repeater Device ID Local Intrfce RouterB Ser 0 SwitchA0050BD855780 Eth 0
Holdtme 148 167
Capability R T S
Platform 2522 1900
Port ID Ser 1 2
SwitchA also provides its Mac address © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—56
Using the show cdp entry Command SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
10.1.1.1
10.1.1.2
RouterB 10.2.2.1
SwitchB 10.2.2.2
RouterA#sh cdp entry * ------------------------Device ID: RouterB Entry address(es): IP address: 10.1.1.2 Platform: cisco 2522, Capabilities: Router Interface: Serial0, Port ID (outgoing port): Serial1 Holdtime : 168 sec Version : Cisco Internetwork Operating System Software IOS (tm) 2500 Software (C2500-JS-L), Version 12.0(3), RELEASE SOFTWARE (fci) Copyright (c) 1986-1999 by cisco Systems, Inc. Compiled Mon 08-Feb-99 18:18 by phanguye © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—57
Additional CDP Commands SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
10.1.1.1
10.1.1.2
RouterB 10.2.2.1
SwitchB 10.2.2.2
RouterA#sh cdp traffic CDP counters : Packets output: 56, Input: 38 Hdr syntax: 0, Chksum error: 0, Encaps failed: 3 No memory: 0, Invalid packet: 0, Fragmented: 0
RouterA#sh cdp interface BRI0 is administratively down, line protocol is down Encapsulation HDLC Sending CDP packets every 60 seconds Holdtime is 180 seconds © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—58
Using Telnet to Connect to Remote Devices SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
10.1.1.1
10.1.1.2
RouterB 10.2.2.1
SwitchB 10.2.2.2
RouterA#telnet 10.2.2.2 Trying 10.2.2.2 ... Open ------------------------------------------------Catalyst 1900 Management Console Copyright (c) Cisco Systems, Inc. 1993-1998 All rights reserved. Enterprise Edition Software Ethernet Address: 00-90-86-73-33-40 PCA Number: 73-2239-06 PCA Serial Number: FAA02359H8K Remote device Model Number: WS-C1924-EN System Serial Number: FAA0237X0FQ . . SwitchB> © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—59
Viewing Telnet Connections SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
RouterA#sh session Conn Host 1 10.1.1.2 * 2 10.3.3.2
RouterA#sh user Line User * 0 con 0 11 vty 0
© 1999, Cisco Systems, Inc.
10.1.1.1
RouterB
10.1.1.2
Address 10.1.1.2 10.3.3.2
Host(s) 10.1.1.2 10.3.3.2 idle
10.2.2.1
Byte 0 0
SwitchB 10.2.2.2
Idle Conn Name 1 10.1.1.2 0 10.3.3.2
Idle Location 3 2 1 10.1.1.2
www.cisco.com
ICND—510
Suspending a Telnet Session SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
RouterB#x RouterA#sh session Conn Host 1 10.1.1.2 RouterA#resume 1 RouterB#
© 1999, Cisco Systems, Inc.
10.1.1.1
10.1.1.2
Address 10.1.1.2
www.cisco.com
RouterB 10.2.2.1
Byte 0
SwitchB 10.2.2.2
Idle Conn Name 1 10.1.1.2
ICND—511
Closing a Telnet Session SwitchA
RouterA
S1
S0 10.3.3.2
10.3.3.1
10.1.1.1
10.1.1.2
RouterB 10.2.2.1
SwitchB 10.2.2.2
Closing the current RouterA#disconnect Closing connection to 10.3.3.2 [confirm] session opened by you
Closing a session opened by a remote device
RouterA#clear line 11 [confirm] [OK]
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—512
Using the ping and trace Commands Router##ping 10.1.1.10 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 10.1.1.10, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 4/4/4 ms Router#trace 10.1.1.10 Type escape sequence to abort. Tracing the route to 10.1.1.10 1 10.1.1.10 4 msec 4 msec 4 msec Router#
Test connectivity and path to a remote device © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—513
Router Power on/Bootup Sequence • Power on self test (POST) • Load and run bootstrap code • Find the IOS software • Load the IOS software • Find the configuration • Load the configuration • Run
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—514
Router Internal Components NVRAM Config register
RAM
ROM Interfaces Flash
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—515
ROM Functions ROM
Bootstrap
POST show version
Mini IOS
ROM monitor
Console
Contains microcode for basic functions © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—516
Finding the IOS show startupconfig
NVRAM Config register
Flash IOS
© 1999, Cisco Systems, Inc.
Console
show version
Order of search:
1. Check configuration register 2. Parse config in NVRAM 3. Default to first file in Flash 4. Attempt net boot 5. RXBOOT 6. ROMMON www.cisco.com
ICND—517
Router Startup Flow Chart Boot field =1 0x1
START
Boot system Yes commands ?
Check startup config
No
Yes
Boot field =0 0x0
No
No No Yes
Run ROM Monitor
Yes
Use IOS from Flash
Attempt to get IOS from network
5 failures ?
No Use IOS in ROM (RXBoot mode)
Load IOS
Yes
Config reg bit 13=1 ?
Config reg bit 6=1 ?
No
Success ?
No
Yes
© 1999, Cisco Systems, Inc.
Valid IOS in Flash ?
No
Yes
Do what they say
www.cisco.com
Yes
Valid config ?
No
Use file from Network
NORMAL START UP COMPLETE
Yes
SETUP DIALOG
ICND—518
Determining the Current Configuration Register Value wg_ro_a#show version Cisco Internetwork Operating System Software IOS (tm) 2500 Software (C2500-JS-L), Version 12.0(3), RELEASE SOFTWARE (fc1) Copyright (c) 1986-1999 by cisco Systems, Inc. Compiled Mon 08-Feb-99 18:18 by phanguye Image text-base: 0x03050C84, data-base: 0x00001000 ROM: System Bootstrap, Version 11.0(10c), SOFTWARE BOOTFLASH: 3000 Bootstrap Software (IGS-BOOT-R), Version 11.0(10c), RELEASE SOFTWARE (fc1) wg_ro_a uptime is 20 minutes System restarted by reload System image file is "flash:c2500-js-l_120-3.bin" --More-Configuration register is 0x2102
Configuration register value in show version © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—519
Configuration Register Values Router#configure terminal Router(config)#config-register 0x2102 [Ctrl-Z] Router#reload
• Configuration register bits 3, 2, 1, and 0 set boot option
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—520
Configuration Register Values Router#configure terminal Router(config)#config-register 0x2102 [Ctrl-Z] Router#reload
• Configuration register bits 3, 2, 1, and 0 set boot option Configuration Register Boot Field Value 0x0
© 1999, Cisco Systems, Inc.
Meaning Use ROM monitor mode (Manually boot using the b command)
www.cisco.com
ICND—521
Configuration Register Values Router#configure terminal Router(config)#config-register 0x2102 [Ctrl-Z] Router#reload
• Configuration register bits 3, 2, 1, and 0 set boot option Configuration Register Boot Field Value
© 1999, Cisco Systems, Inc.
Meaning
0x0
Use ROM monitor mode (Manually boot using the b command)
0x1
Automatically boot from ROM (Provides IOS subset)
www.cisco.com
ICND—522
Configuration Register Values Router#configure terminal Router(config)#config-register 0x2102 [Ctrl-Z] Router#reload
• Configuration register bits 3, 2, 1, and 0 set boot option Configuration Register Boot Field Value
Meaning
0x0
Use ROM monitor mode (Manually boot using the b command)
0x1
Automatically boot from ROM (Provides IOS subset)
0x2 to 0xF
Examine NVRAM for boot system commands (0x2 default if router has Flash)
• Check configuration register value with show version © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—523
Loading the IOS from Flash RAM IOS
Flash IOS
Console show flash
Flash file is decompressed into RAM © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—524
show flash Command
wg_ro_a#sh flash System flash directory: File Length Name/status 1 10084696 c2500-js-l_120-3.bin [10084760 bytes used, 6692456 available, 16777216 total] 16384K bytes of processor board System flash (Read ONLY)
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—525
Loading the Configuration RAM
NVRAM
Config
Config
IOS
show runningconfig
show startupconfig Console Setup utility
• Load and execute config from NVRAM • If no config in NVRAM, enter setup mode © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—526
show running and show startup Commands In RAM
In NVRAM
wg_ro_c#show running-config Building configuration...
wg_ro_c#show startup-config Using 1359 out of 32762 bytes ! version 12.0 ! -- More --
Current configuration: ! version 12.0 ! -- More --
Display current and saved configuration
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—527
Sources of Configurations RAM Config
copy running startup copy startup running (merge)
NVRAM Config
• NVRAM
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—528
Sources of Configurations RAM Config
copy running startup copy startup running (merge)
NVRAM Config
config term (merge)
• NVRAM • Terminal
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—529
Sources of Configurations RAM
copy running startup
Config
copy startup running (merge)
NVRAM Config
config term (merge) copy tftp run Console (merge)
• NVRAM
copy run tftp
• Terminal • TFTP server © 1999, Cisco Systems, Inc.
copy tftp start copy start tftp
TFTP server
www.cisco.com
ICND—530
Sources of Configurations RAM
copy running startup
Config
copy startup running (merge)
NVRAM Config
config term (merge) copy tftp run Console (merge)
• NVRAM
copy run tftp
• Terminal • TFTP server
copy tftp start copy start tftp
TFTP server
erase start Blank 000000 000000
• Erase Start © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—531
copy run tftp and copy tftp run Commands wg_ro_a#copy running-config tftp Address or name of remote host []? 10.1.1.1 Destination filename [running-config]? wgroa.cfg .!! 1684 bytes copied in 13.300 secs (129 bytes/sec) wg_ro_a#copy tftp running-config Address or name of remote host []? 10.1.1.1 Source filename []? wgroa.cfg Destination filename [running-config]? Accessing tftp://10.1.1.1/wgroa.cfg... Loading wgroa.cfg from 10.1.1.1 (via Ethernet0): ! [OK - 1684/3072 bytes] 1684 bytes copied in 17.692 secs (99 bytes/sec)
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—532
Cisco IOS File Systems and Devices
RAM
NVRAM
system:
nvram:
TFTP server
Flash
tftp:
flash: © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—533
Managing IOS Images c2500jsl_1203.bin
Network server
Router
FLASH
© 1999, Cisco Systems, Inc.
Network server
www.cisco.com
ICND—534
Preparing for a Network Backup Image
Network server
Router
• Check access to the server
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—535
Preparing for a Network Backup Image
Network server
Router
• Check access to the server • Check space available on the server
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—536
Preparing for a Network Backup Image c2500jsl_1203.bin
Network server
Router
• Check access to the server • Check space available on the server • Check file naming convention
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—537
Preparing for a Network Backup Image c2500jsl_1203.bin
Network server
Router
• Check access to the server • Check space available on the server • Check file naming convention • Create file on server if required © 1999, Cisco Systems, Inc.
www.cisco.com
ICND—538
Verifying Memory and Deciphering Image Filenames wg_ro_a#show flash System flash directory: File Length Name/status 1 10084696 c2500-js-l_120-3.bin [10084760 bytes used, 6692456 available, 16777216 total] 16384K bytes of processor board System flash (Read ONLY)
Verify Flash memory has room for the IOS image
© 1999, Cisco Systems, Inc.
www.cisco.com
ICND—539
Creating a Software Image Backup FLASH
copy flash tftp
Network server
wg_ro_a#copy flash tftp Source filename []? c2500-js-l_120-3.bin Address or name of remote host []? 10.1.1.1 Destination filename [c2500-js-l_120-3.bin]? !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!