Thứ Hai, 28 tháng 10, 2019

Recovering Switch Cisco from a Software Failure

Recovering from a Software Failure

Cách 1:

We just got our shipment of 3850 Switches in and Im upgrading all of them to the latest IOS and its a real treat to do. If you were use to doing it via tftp you will be blown away on how easy it is.

Steps
1) Down load new IOS-XE bin file from Cisco
2) Save it to a USB drive. Usb Drive must be formatted with FAT16 or 32. Mine was 32
3) Plug into 3850 Switch
4) dir usbflash0:
5) Make sure your IOS is there. "cat3k_caa-universalk9.SPA.03.06.02a.E.152-2a.E2.bin"
6) copy from usb to flash "copy usbflash0:cat3k_caa-universalk9.SPA.03.06.02a.E.152-2a.E2.bin flash:"
7) dir flash: and make sure it copied over.
8. Run the command Switch#software install file flash:cat3k_caa-universalk9.SPA.03.06.02a.E.152-2a.E2.bin switch 19) When is done doing the upgrade you will need to clean up the old files that are in flash
10) Run Switch#software clean
11) Check your flash for the new IOS package files and reboot.



Keep this in mind, All the new package files are extracted from the bin file. So if you blow up your flash you can now boot the bin file from the USB stick with "boot usbflash0:IOS name" and your back in business.

I had another 24 Port switch that was blew up do to the bug in the 3.0.0 IOS release and you have to boot it in boot loader mode. Basically same as the old rommon mode.

1) Power up switch and wait for the SYS light to start blinking green.
2) Hold the Mode button for about 20 seconds and the lights will glow amber, release the button.
3) You will be sitting on the Switch: prompt.
4) Here is where it gets cool.
5) Boot your bin file in the USB stick
6) Once your back into the switch, go ahead and delete all files in flash. I do them one by one.
7) Now copy the bin file from USB stick into your cleaned out flash
8. Now we have to expand the bin file.
9) Switch# software expand file flash: cat3k_caa-universalk9.SPA.03.02.02.SE.150-1.EX2.bin to flash:
Switch#Config t
Switch(config)# no boot system
Switch(config): boot system switch all flash: packages.conf
Switch#wr10) Reboot the switch and you back in business.

Hopefully this will save you some time in your upgrades. If you like this, Don't be afraid to use the REP button!

Cách 2:


Before you begin

This recovery procedure requires that you have physical access to the switch.
This procedure uses boot loader commands and TFTP to recover from a corrupted or incorrect image file.

Procedure


Step 1
From your PC, download the software image file (image.bin ) from Cisco.com.
Step 2
Load the software image to your TFTP server.
Step 3
Connect your PC to the switch Ethernet management port.
Step 4
Unplug the switch power cord.
Step 5
Press the Mode button, and at the same time, reconnect the power cord to the switch.
Step 6
From the bootloader (ROMMON) prompt, ensure that you can ping your TFTP server.
  1. Set the IP address switch: set IP_ADDR ip_address subnet_mask

    Example:

    switch: set IP_ADDR 192.0.2.123/255.255.255.0
    
    
  2. Set the default router IP address switch: set DEFAULT_ROUTER ip_address

    Example:

    switch: set DEFAULT_ROUTER 192.0.2.1
    
    
  3. Verify that you can ping the TFTP server switch: ping ip_address_of_TFTP_server


Example:

switch: ping 192.0.2.15 
ping 192.0.2.1 with 32 bytes of data...
Host 192.0.2.1 is alive.
switch:

Step 7
Verify that you have a recovery image in your recovery partition (sda9:).


This recovery image is required for recovery using the emergency-install feature.

Example:


switch: dir sda9:
Directory of sda9:/

    2  drwx  1024       .
    2  drwx  1024       ..
   11  -rw-  18923068   c3850-recovery.bin

36939776 bytes available (20830208 bytes used)
switch:

Step 8
From the bootloader (ROMMON) prompt, initiate the emergency-install feature that assists you in recovering the software image on your switch.


WARNING: The emergency install command will erase your entire boot flash!

Example:

Switch#  
emergency-install tftp://192.0.2.47/cat3k_caa-universalk9.SSA.03.12.02.EZP.150-12.02.EZP.150-12.02.EZP.bin

The bootflash will be erased during install operation, continue (y/n)?y
Starting emergency recovery (tftp://192.0.2.47/cat3k/cat3k_caa-universalk9.SPA.03.02.00.SE.150-1.EX.bin)...
Reading full image into memory......................done
Nova Bundle Image
--------------------------------------
Kernel Address : 0x6042e5cc
Kernel Size : 0x318261/3244641
Initramfs Address : 0x60746830
Initramfs Size : 0xdb0fb9/14356409
Compression Format: .mzip

Bootable image at @ ram:0x6042e5cc
Bootable image segment 0 address range [0x81100000, 0x81b80000] is in range [0x80180000, 0x90000000].
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
File "sda9:c3850-recovery.bin" uncompressed and installed, entry point: 0x811060f0
Loading Linux kernel with entry point 0x811060f0 ...
Bootloader: Done loading app on core_mask: 0xf

### Launching Linux Kernel (flags = 0x5)



Initiating Emergency Installation of bundle tftp://192.0.2.47/cat3k/cat3k_caa-universalk9.SSA.03.12.02.EZP.150-12.02.EZP.150-12.02.EZP.bin


Downloading bundle tftp://192.0.2.47/cat3k/cat3k_caa-universalk9.SSA.03.12.02.EZP.150-12.02.EZP.150-12.02.EZP.bin...
Validating bundle tftp://192.0.2.47/cat3k/cat3k_caa-universalk9.SSA.03.12.02.EZP.150-12.02.EZP.150-12.02.EZP.bin...
Installing bundle tftp://192.0.2.47/cat3k/cat3k_caa-universalk9.SSA.03.12.02.EZP.150-12.02.EZP.150-12.02.EZP.bin...
Verifying bundle tftp://192.0.2.47/cat3k/cat3k_caa-universalk9.SSA.03.12.02.EZP.150-12.02.EZP.150-12.02.EZP.bin...
Package cat3k_caa-base..pkg is Digitally Signed
Package cat3k_caa-drivers.SPA.03.02.00.SE.pkg is Digitally Signed
Package cat3k_caa-infra.SPA.03.02.00.SE.pkg is Digitally Signed
Package cat3k_caa-iosd-universalk9.SPA.03.02.00.SE.pkg is Digitally Signed
Package cat3k_caa-platform.SPA.03.02.00.SE.pkg is Digitally Signed
Package cat3k_caa-wcm.SPA.03.02.00.SE.pkg is Digitally Signed
Preparing flash...
Syncing device...
Emergency Install successful... Rebooting
Restarting system.



Booting...(use DDR clock 667 MHz)Initializing and Testing RAM +++@@@@####...++@@++@@++@@++@
 
 

0 nhận xét:

Đăng nhận xét