How to restore and upgrade a Cisco router IOS image

Source: Internet
Author: User

Due to historical reasons, Cisco's vro products are rich and complex. Cisco vro's dedicated OS IOS image also has multiple versions at the same time, the following sections discuss two types of Cisco routers that load different versions of IOS image files.

1. Cisco, Series

1. methods and steps for restoring IOS images

1) connect the COM1 port of the PC to the console port of the vro, and use the super terminal software of the PC to access the vro; 2) Enable the power switch of the vro, press Ctrl + break on the keyboard within 30 seconds to interrupt the normal startup of the router to enter rom monitoring mode. The prompt on the screen is as follows:

>

3) type the following command:

> O/r 0x2101

Change the default value of the vro virtual register (0x2102 );

4) type the restart command:

> I

When the screen displays the following information: System Bootstrap, Version 5.2 (8a), RELEASE SOFTWARE

Copyright (c) 1986-1995 by cisco Systems

2500 processor with 1024 Kbytes of main memory

...

Press RETURN to get started!

5) the router automatically enters the rom startup mode when the virtual register value is 0x2101:

Router (boot)>

6) at this time, restore the IOS image file on the TFTP server to the flash memory of the router, and then type the following commands in sequence:

Router (boot)> en

Router (boot) # copy tftp flash

System flash directory:

No files in System flash

[0 bytes used, 4194304 available, 4194304 total] Address or name of remote host [255.255.255.255]? 192.168.18.168 (the IP address has been technically processed, the same below)

Source file name? Igs-i-l.110-22a.bin (IOS image file name)

Destination file name [igs-i-l.110-22a.bin]?

Accessing file igs-i-l.110-22a.bin on 192.168.18.168 ......

Loading igs-i-l.110-22a.bin from 192.168.18.168 (via Ethernet0 ):! [OK]

Device needs erasure before copying new file

Erase flash device before writing? [Confirm] Copy igs-i-l.110-22a.bin from server as igs-i-l.110-22a.bin into Flash WITH erase? [Yes/no] y

Erasing device ...... Eeeeeeeeeeeeeeeeee ...... Erased

Loading igs-i-l.110-22a.bin from 192.168.18.168 (via Ethernet0 ):!!!!!!!!!!!!!!!!!!!! (! Indicates that the recovery is successful)

7) restore the default value of the vro virtual register (0x2102), and restore the normal startup sequence of the vro. type the following commands in sequence:

Router (boot) # conf t

Router (boot) (config) # config-register 0x2102

Router (boot) (config) # exit

Router (boot) # wr

Router (boot) # reload

2. IOS image upgrade methods and steps

1) back up the file to the TFTP server before the upgrade, and enter the following command: router # copy bootflash tftp (the Cisco 2500 series routers do not have bootflash, and the corresponding rom is used)

Router # copy flash tftp

Router # copy startup-config tftp

2) because the Cisco, and series routers do not allow flash memory to be rewritten in normal working conditions, the IOS image can be upgraded only when the rom (or bootflash) Startup Mode is enabled. Enter the following commands in sequence:

Router # conf t

Machine (config) # config-register 0x2101

Router (config) # exit

Router # wr

Router # reload

3) after the vro is restarted, it enters the rom (or bootflash) Startup Mode. Copy the new IOS image file from the TFTP server to the flash memory of the vro:

Router (boot) # copy tftp flash

4) restore the default value of the vro virtual register (0x2102), and restore the normal startup sequence of the vro. type the following commands in sequence:

Router (boot) # conf t

Router (boot) (config) # config-register 0x2102

Router (boot) (config) # exit

Router (boot) # wr

Router (boot) # reload

Ii. Cisco 1700,2600, 3600,7200 Series

1. methods and steps for restoring IOS images

1) connect the COM1 port of the PC to the console port of the vro, and use the super terminal software of the PC to access the vro; 2) Enable the power switch of the vro, press Ctrl + break on the keyboard within 30 seconds to interrupt the normal startup of the router to enter rom monitoring mode. The prompt on the screen is as follows:

Rommon 1>

3) type the xmodem command:

Rommon 1> xmodem c3640-i-mz.120-10.bin (IOS image file name)

4) then, the router waits for receiving the IOS image file from the PC. Then, click the Send option in the super terminal software and select the IOS image file stored in the PC's local hard disk, after confirmation, the file will be downloaded to the flash memory of the vro. Since the communication bandwidth is only 9600 Potter, the entire file will be downloaded for about 1.5 hours (depending on the file size ), the displayed information is as follows:

Do not start the sending program yet ......

Device does not contain a valid magic number

Dir: cannot open device flash:

WARNING: All existing data in flash will be lost!

Invoke this application only for disaster recovery. Do you wish to continue? Y/n [n]: y Ready to receive file c3640-i-mz.120-10.bin ......

Erasing flash at 0x307c0000

Program flash location 0x30380000

Download Complete!

Program load complete, entry point: 0x80008000, size: 0x38f410 5), The vro restarts automatically, and the screen displays the following information:

Self decompressing the image: ################################# [OK]

...

Press RETURN to get started!

2. IOS image upgrade methods and steps

1) Likewise, back up the key files to the TFTP server before the upgrade. type the following command: router # copy bootflash tftp (no bootflash exists on the Cisco 3600 series routers)

Router # copy flash tftp

Router # copy startup-config tftp

2) Because Cisco 1700,2600, 3600,7200 series routers allow rewriting of flash memory under normal working conditions, you can directly enter the following command to complete online IOS image upgrade:

Router # copy tftp flash

Router # reload

Or, for the sake of insurance (at the cost of stopping the service on the router), upgrade the IOS image only after the rom monitoring mode is enabled. perform the following operations in sequence: 2) press Ctrl + break on the keyboard within 30 seconds after the vro is restarted and the normal startup of the vro is interrupted, and the rom monitoring mode is directly entered. The prompt on the screen is as follows:

Rommon 1>

Alternatively, you can perform the following operations after the router is restarted to enter the rom monitoring mode of the router:

Router # conf t

Router (config) # config-register 0x0

Router (config) # exit

Router # wr

Router # reload

Rommon 1>

3) type the following command to copy the IOS image upgrade file from the TFTP server to the flash memory of the router: rommon 1> B c3640-i-mz.121-2.T 192.168.18.168 program load complete, entry point: 0x80008000, size: 0x4ed478

Self decompressing the image: ################################## [OK]

Loading c3640-i-mz.121-2.T from 192.168.18.168 (via Ethernet0/0 ):!!!!!!!!!!!!!!!

[OK-5166484/10332160 bytes]

4) restore the default value of the vro virtual register (0x2102), and restore the normal startup sequence of the vro. type the following commands in sequence:

Rommon 1> confreg 0x2102

5) type the restart command to make the new configuration take effect and complete the offline upgrade of the IOS image:

Rommon 2> reset

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.