Booting Cisco Router From USB Flash
类型:【转载】
原文作者:【admin】
日期:【March 25, 2020】
原文地址:https://networkrare.com/booting-cisco-router-from-usb-flash/
Booting Cisco Router From USB Flash
We all know that cisco router and switch stores the IOS in flash. Flash is used like a hard drive. When we are booting the router, it loads the IOS file in to RAM from flash. Flash can be external or internal. It depends on hardware model.
Sometime, Router moves into the rommon mode due to IOS corrupt. In this case we need to upload the IOS into flash from tftp, using DNLD process or Xmodem process.
But it is very difficult. If we are having a non technical person on site. who is unable to perform the steps. If we are having technical person on site then it is good.
Now suppose, technical on site person found that flash is got faulty and no spare flash.
In this case we can use USB for boot the router.
How to Boot from USB
First, Upload a valid IOS image into USB. We should avoid to use random IOS image. Best process is that we should use the same image which were using on failed device.
Process Steps(Booting Cisco Router From USB Flash):
- Unload a valid IOS image into USB.
- Connect the USB drive on router’s USB port.
- Enter into rommon mode. This is the default mode if IOS has been corrupt.
- Follow the below command:
rommon 2> dir usbflash0:
program load complete, entry point: 0x8000f000, size: 0x3d240
Directory of usbflash0:
2 …… 14871760-… ..- rw-ipbase c2800nm-mz.124-3.bin
Note: The command is dir usbflashx: where x assumes a value of 0 or 1 depending on which USB port of the router you are using.
Then run the command that orders the router to boot from the image stored on USB flash:
rommon 3> boot usbflash0: c2800nm-ipbase-mz.124-3.bin
program load complete, entry point: 0x8000f000, size: 0x3d240
program load complete, entry point: 0x8000f000, size: 0xe2eb30
Self decompressing the image:
################################################## ###################################################################################################################################################################### [OK]
Once the router has booted up, you can now work with the normal IOS command line interface. Now We can copy the image from USB flash and place it into the internal router’s flash memory as follow:
Router> enable
Router # copy usbflash0: c2800nm-ipbase-mz.124-3.bin flash: c2800nm-ipbase-mz.124-3.bin
now we can boot the device from new image. If we are not booting the device after upload the IOS in flash then also no issue. But don’t forget to change the boot sequence command.
Otherwise, It can create a problem, if router restarted and we removed the USB. In this case router will try to find the IOS file in USB but USB drive is not connected. So router will move into the rommon mode again.
R1(config)#boot system flash: c2800nm-ipbase-mz.124-3.bin
We can also take the IOS backup from flash to USB. below is the example: