# Recovering Software Image

<details id="bkmrk-introduction-this-se"><summary>Introduction</summary>

This section explains how to recover ICX devices from image installation failure or deleted or corrupted flash images.

</details><details id="bkmrk-method-important-tex"><summary>Method</summary>

**<span style="color: rgb(224, 62, 45);">IMPORTANT</span>**

<span style="color: rgb(224, 62, 45);">Text marked in **Red** is a variable command and may differ from your configuration.</span>

- Connect a console cable from the ICX switches console port to your PC/laptop.
- Connect an Ethernet cable from the management port (the port located under the console port on the ICX switch) to the PC/laptop which will need to host a TFTP server.  
    boot up your ICX switch while continuing to press 'B'. The device will be in boot mode for recovery.
- Set the TFTP server IP address that hosts a valid ICX software image using the setenv serverip command.
    
    ICX 7450-48&gt; setenv serverip <span style="color: rgb(224, 62, 45);">**192.168.88.1**</span>
- Set the IP address, gateway IP address, and netmask for the ICX switch (management port), and save the configuration using the setenv ipaddr, setenv gatewayip, setenv netmask, and saveenv commands.
    
    ICX 7450-48&gt; setenv ipaddr <span style="color: rgb(224, 62, 45);">**192.168.88.2**</span>  
    ICX 7450-48&gt; setenv gatewayip <span style="color: rgb(224, 62, 45);">**192.168.88.254**</span>  
    ICX 7450-48&gt; setenv netmask <span style="color: rgb(224, 62, 45);">**255.255.255.0**</span>  
    ICX 7450-48&gt; saveenv
    
      
    Note: The IP address and the gateway IP address set for the device management port should be for the same subnet as the TFTP server NIC.
- Enter the printenv command to verify the IP addresses that you configured for the device and the TFTP server.
    
    ICX 7450-48&gt; printenv   
    baudrate=9600  
    ipaddr=192.168.88.2  
    gatewayip=192.168.88.254  
    netmask=255.255.255.0  
    serverip=192.168.88.1  
    uboot=brocade/ICX7450/bootcode/spz10115  
    Version:10.1.06T215 (May 15 2015 - 11:28:23)
- Test the connectivity to the TFTP server from the device using the ping command to ensure a working connection.
    
    ICX 7450-48&gt; ping <span style="color: rgb(224, 62, 45);">**192.168.88.1**</span>  
    ethPortNo = 0  
    Using egiga0 device  
    host 192.168.88.1 is alive
- Provide the file name of the image that you want to copy from the TFTP server using the setenv image\_name command.
    
    ICX 7450-48&gt; setenv image\_name <span style="color: rgb(224, 62, 45);">**SPR08090.bin**</span>
- Update the flash using the update\_primary or update\_secondary command as appropriate.
    
    ICX 7450-48&gt; update\_primary
- Set the file name of the boot image which was copied from the tftp server.
    
    &gt; setenv uboot <span style="color: rgb(224, 62, 45);">**SPR08090.bin**</span>
- Update the uboot file.
    
    ICX 7450-48&gt; update\_uboot
- Load the image from the primary or secondary flash using the boot\_primary or boot\_secondary command as appropriate.
    
    ICX 7450-48&gt; boot\_primary
- *Optional/Recommended:* Providing the switch boots correctly you may now want to ensure both primary and secondary banks are hosting valid and working software images. To do this you can use the method above (steps 8-11 on the opposite bank that you previously flashed) or refer to the following article(s):
- [Upgrading ICX Firmware via USB](https://techblog.jcditservices.com/books/ruckus/page/upgrading-icx-firmware-via-usb "Upgrading ICX Firmware via USB")
- [Upgrading ICX Firmware via TFTP](https://techblog.jcditservices.com/books/ruckus/page/upgrading-icx-firmware-via-tftp "Upgrading ICX Firmware via TFTP")

</details>