Overview
This guide provides a CCNA-level introduction to backing up, restoring, upgrading, and recovering Cisco IOS devices. It also covers Packet Tracer, GNS3, Cisco Modeling Labs (CML), Wireshark, Windows OpenSSH, PuTTY, PuTTYgen, and Pageant.
Recovery, boot, and firmware commands are not universal. Always follow the procedure for your exact model and IOS/IOS XE release. Do not format or erase flash unless you understand the platform-specific recovery path and have another valid image available.
1. Cisco Device Storage
| Component | Typical contents | Persists after reload? |
|---|---|---|
| RAM | Running configuration, routing tables, ARP table, active processes | No — lost at power-off |
| NVRAM | Startup configuration (common location) | Yes |
| Flash / bootflash | IOS or IOS XE images, package files, other persistent files | Yes |
| ROM | Bootstrap and low-level code | Yes (firmware) |
| ROMMON | Recovery and boot environment | Yes |
| USB storage | Alternate boot/recovery image (when supported) | Yes |
RAM holds the running-config and operational state. NVRAM commonly stores startup-config. Flash or bootflash stores IOS images and related files. ROM loads the bootstrap; ROMMON is the recovery shell when normal boot fails.
Do not use "NVFlash" as a standard Cisco IOS storage term. Learn NVRAM, flash, bootflash, ROM, and ROMMON separately.
show version show boot show file systems dir dir flash: dir bootflash: show running-config show startup-config
2. TFTP Fundamentals
Trivial File Transfer Protocol (TFTP) uses UDP port 69. It is simple but has no built-in encryption or authentication — use it only on trusted or isolated networks.
Requirements:
- The TFTP server must allow the device to read or write files.
- Firewalls and Windows network profiles can block transfers.
- The Cisco device needs IP connectivity to the server.
ping <TFTP-SERVER-IP> show ip interface brief show file systems dir flash:
3. Backing Up Configurations
copy running-config tftp: copy startup-config tftp:
Typical interactive prompts:
Address or name of remote host []?
Destination filename [R1-confg]?
Use clear filenames such as:
R1-running-2026-07-10.cfgR1-startup-known-good.cfg
Configuration backups may contain passwords and keys. Store them securely and treat them like credentials.
4. Restoring a Known-Good Configuration
copy tftp: startup-config reload
copy tftp: running-config
Copying a configuration into running-config normally merges it with the existing configuration. It does not necessarily remove commands that are already present.
Where supported (platform- and IOS-dependent):
configure replace tftp://192.0.2.10/R1-known-good.cfg force
Check support with configure replace ? on your device.
5. Backing Up and Copying IOS Images
copy flash:<IMAGE-NAME.bin> tftp: copy tftp: flash:
On many newer platforms, use bootflash: instead of or in addition to flash:.
Before deleting an image, confirm the replacement finished copying, has the correct size, a valid hash, is compatible with hardware, and is referenced by boot configuration.
6. Pre-Upgrade Checklist
- Confirm the exact device model.
- Check current IOS or IOS XE version.
- Read the release notes.
- Check memory and flash requirements.
- Confirm licensing and entitlement.
- Back up running-config.
- Back up startup-config.
- Record existing boot variables.
- Keep the current working image.
- Verify the new image hash.
- Ensure console or out-of-band access.
- Schedule an appropriate maintenance window.
- Have a rollback plan.
show version show inventory show boot show license summary show file systems dir flash: dir bootflash:
7. Image Integrity Verification
verify /md5 flash:<IMAGE-NAME.bin>
Supported hash options vary by platform and release. Compare the calculated hash with the value published by the authorized software source.
8. Classic IOS Boot Variables
This example applies to many traditional monolithic IOS routers. It does not apply identically to every IOS XE switch or router.
configure terminal no boot system boot system flash:<IMAGE-NAME.bin> end copy running-config startup-config show boot
Some devices use bootflash. Some IOS XE systems boot from packages.conf. Always check the platform-specific upgrade procedure.
9. Cisco Software Image Types
At CCNA scope, recognize these naming patterns:
| Term | Meaning |
|---|---|
Classic monolithic IOS .bin | Single image file on many older routers |
| IOS XE bundle mode | Bundle image on flash |
| IOS XE install mode | Packages installed from a bundle |
packages.conf | Boot pointer for installed packages on IOS XE |
| Package files | Individual feature packages in install mode |
k9 | Cryptographic feature set indicator in many image names |
universalk9 | Common IOS XE image family name |
ipbase, lanbase, adventerprisek9 | Older naming examples — names vary by generation |
Feature availability depends on hardware, IOS release, license, Smart Licensing status, and image family. Not every k9 image supports every SSH or cryptographic feature.
10. Legal Sources for IOS Images
- Physical-device software should come from Cisco's official software download service or another authorized source.
- Downloads may require a Cisco account and valid entitlement.
- Do not use torrents, random archive sites, file-sharing forums, or unverified images.
- Cisco Modeling Labs includes licensed virtual reference platforms — licensing terms control usage.
- Packet Tracer includes simulated devices — students do not need to locate IOS images.
- GNS3 does not legally provide proprietary Cisco IOS images for download.
This site does not provide instructions for bypassing licensing or entitlement restrictions.
11. ROMMON and the Configuration Register
ROMMON (ROM monitor) is the low-level recovery environment when normal IOS boot fails.
Classic configuration-register values on many traditional routers:
| Value | Behavior |
|---|---|
0x2102 | Normal boot — load startup-config |
0x2142 | Ignore startup-config during boot (classic password recovery on supported older routers) |
The following sequence is an older-router example. Newer platforms use different recovery flows. Use the exact procedure for your device model.
rommon 1 > confreg 0x2142 rommon 2 > reset
After boot:
enable copy startup-config running-config configure terminal enable secret <NEW-SECRET> config-register 0x2102 end copy running-config startup-config reload
Why copy startup-config to running-config first? The running configuration is minimal after 0x2142 boot — you must load the saved config before changing credentials.
Failing to restore config-register 0x2102 may cause the router to continue ignoring startup-config on every reload.
12. Older Catalyst Switch Password Recovery
This is not the same as router 0x2142 recovery. Newer Catalyst switches may use different processes.
switch: flash_init switch: dir flash: switch: rename flash:config.text flash:config.old switch: boot
After boot, restore and merge:
rename flash:config.old flash:config.text copy flash:config.text running-config
Then change credentials and save. Some switches use the Mode button during recovery. VLAN data may be stored separately from config.text.
13. Missing or Damaged IOS Image
High-level recovery options (platform-dependent):
- Boot another valid image already in flash
- Boot from USB when supported
- ROMMON network recovery when supported
- TFTP recovery when supported
- XMODEM on some older devices (slow last resort)
- IOS XE install or recovery procedures on newer platforms
- Restore boot variables after recovery
Do not format or erase flash unless you fully understand the platform-specific recovery procedure and have another valid image available.
14. Packet Tracer, GNS3, CML, and Physical Hardware
| Platform | Strengths | Limitations |
|---|---|---|
| Packet Tracer | Best for CCNA fundamentals; fast setup; low system requirements | Simulated command set — some commands and behaviors unavailable |
| GNS3 | Virtual appliances; mixed vendors; realistic packet behavior; Wireshark integration | Requires compatible images/appliances; more setup and resources |
| Cisco Modeling Labs | Cisco virtual reference platforms; realistic Cisco behavior; licensed images | Higher resource requirements; licensing terms apply |
| Physical hardware | Real cabling; console recovery; flash and ROMMON practice; hardware-specific behavior | Power, space, and physical interfaces required |
Packet Tracer behavior should not be treated as proof that every physical IOS command works identically.
15. Capturing Traffic With Wireshark
GNS3 link capture
- Start both virtual devices.
- Right-click the link.
- Select Start Capture.
- Open the capture in Wireshark.
- Generate test traffic.
- Apply a display filter.
- Stop and save the capture if needed.
Useful display filters:
| Filter | Traffic |
|---|---|
arp | ARP |
icmp | ICMP |
dns | DNS |
tcp.port == 23 | Telnet |
tcp.port == 22 | SSH |
udp.port == 69 | TFTP |
ospf | OSPF |
dhcp | DHCP |
Telnet vs SSH exercise
- Start a Telnet session and inspect packets — contents are readable in cleartext.
- Start an SSH session — payload is encrypted.
- Do not use real credentials in the Telnet demonstration.
Physical-network capture may require a network TAP, hub, switch port mirroring (SPAN), or capturing directly from the endpoint.
16. DNS Testing With nslookup
nslookup example.com nslookup example.com 192.0.2.53 nslookup set type=mx example.com exit
Concepts:
- Forward lookup — name to IP
- Querying a specific DNS server — second form above
- Record types — A, MX, etc.
- NXDOMAIN — name does not exist
- DNS failure vs IP connectivity failure — ping the server IP if DNS fails
PowerShell (when available):
Resolve-DnsName example.com
17. Windows OpenSSH
ssh [email protected] ssh -v [email protected] ssh-keygen ssh-add ssh-add -l
- Modern Windows includes a built-in OpenSSH client.
-vprovides troubleshooting output.- Host-key warnings should not be ignored without verifying why the key changed.
- Older Cisco hardware may support limited SSH algorithms that modern clients disable by default.
Avoid permanently disabling modern cipher and algorithm requirements on your workstation. Prefer platform-appropriate IOS images or documented workarounds for lab hardware only.
18. PuTTY, PuTTYgen, and Pageant
| Tool | Role |
|---|---|
| PuTTY | SSH, Telnet, and serial terminal client |
| PuTTYgen | Generates or converts SSH keys; exports multiple formats |
| Pageant | Holds unlocked private keys in memory for PuTTY sessions |
| Method | Notes |
|---|---|
| PuTTY sessions | GUI saved sessions; common in Windows labs |
| Windows OpenSSH | Built-in CLI client |
| Password authentication | Simple; credentials sent each login (SSH encrypts the session) |
| Public-key authentication | Stronger automation-friendly access |
| SSH agent usage | ssh-add / Pageant supply keys without retyping passphrases |
Cisco public-key authentication on IOS varies significantly by version — treat as an advanced topic beyond CCNA core configuration.
19. Recovery and Upgrade Verification
Post-change checklist:
show version show boot show logging show ip interface brief show interfaces status show ip route show cdp neighbors show license summary show running-config ping <NEXT-HOP> copy running-config startup-config
A device reaching the CLI does not by itself prove recovery or upgrade is complete. Also verify:
- Interfaces and VLANs
- Routing and neighbor relationships
- Management access
- Licensing
- Logs
- Boot variables
- Saved configuration
20. Final Lab Exercises
Exercise 1: Back up a router's running and startup configurations to TFTP.
Exercise 2: Change the hostname, restore the startup configuration from TFTP, and reload.
Exercise 3: Capture a Telnet session and an SSH session in GNS3 and compare cleartext vs encrypted payloads.
Exercise 4: Use nslookup against the default DNS server, then against a specific DNS server.
Exercise 5: Inspect flash, boot variables, IOS version, and file systems without making changes.
Exercise 6: Write a recovery plan for a router whose primary IOS image is missing — include alternate boot sources, TFTP/ROMMON options for your platform, and rollback steps. Do not intentionally erase flash or brick a device for this exercise.
