User Tools

Site Tools


failsafe_mode_recovery

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
failsafe_mode_recovery [2018/02/12 11:44]
ispyisail [Failsafe recovery via telnet]
failsafe_mode_recovery [2019/04/28 09:55]
ispyisail [Factory Reset]
Line 1: Line 1:
-So your router has become unresponsive and you have heard the horror stories of 'bricked' routers and are in panic mode.  Relax my friendI have flashed 100s of times and recovered unresponsive routers dozens of times.  I have only complete destroyed 1 router in my sordid career.  Chances are excellent that your router can be recovered.  Below are a couple of tricks of the trade.+====== Failsafe Mode, Factory Reset, and Recovery Mode ======
  
-Alternatively you might follow the closely related [[http://wiki.openwrt.org/doc/howto/generic.failsafe|OpenWRT failsafe instructions]]+===== Gargoyle (Basic) ===== 
 +==== Factory Reset ====
  
-===== Failsafe recovery via ssh =====+With the Gargoyle router fully powered up (boot sequence finished) hold the router "reset" button for 10 seconds to enable router reset. Wait around 2 minutes for the process to finish. Don't interrupt the router while the process is taking place.
  
-This procedure assumes that: +//NoteThe button hold time is officially between 3 and 90 seconds// 
-  - you had a good Gargoyle install on the router +
-  - you messed up your settings +
-  - you can no longer get to the Gargoyle Web interface+
  
-NOTEUnplug all external drives from the router or they will be erased by the firstboot process.+//NoteNot enabled for all router models//
  
-Open a terminal and: 
-  - type //ssh root@192.168.1.1// 
-  - provide your password 
-  - at the Gargoyle prompt type //firstboot -y// 
-  - then //reboot -f// 
-  
-The router which should now come up in its default Gargoyle configuration and you will be able to [[getting_started|get started]] again. 
  
  
-===== Failsafe recovery via telnet =====+===== Gargoyle/OpenWrt (Advanced) =====
  
 +[[https://openwrt.org/docs/guide-user/troubleshooting/failsafe_and_factory_reset|Gargoyle/OpenWrt]] offers several ways to “start over” with your router.
  
 +==== Failsafe Mode ====
  
-This procedure assumes that: +  * Failsafe Mode is useful if you have lost control of your device, and it has become inaccessible, perhaps through configuration error. It allows you to reboot the router into a basic operating state, retaining all your packages and (most) settings. ([[https://openwrt.org/docs/guide-user/troubleshooting/failsafe_and_factory_reset#failsafe_mode|see Failsafe Mode]])
-  - you had good Gargoyle install on the router +
-  - you messed up your settings +
-  you can no longer get to the Gargoyle Web interface +
-  - you cannot get to the Gargoyle ssh interface +
-  - you cannot get a ping response from your router+
  
-NOTE: Unplug all external drives from the router or they will be erased by the firstboot process.+==== Factory Reset ====
  
-Firmware recovery changed with 1.10.+  * Factory Reset erases all your packages and settings, returning the router to its initial state after installing OpenWrt([[https://openwrt.org/docs/guide-user/troubleshooting/failsafe_and_factory_reset#factory_reset|see Factory Reset]])
-    Use SSH not Telnet for recovery +
-    - Use “firstboot -y” instead of “firstboot”+
  
 +==== Recovery Mode ====
  
-Procedure for 1.10.x and above+  * Recovery Mode allows you to install new firmware on a router that has become corrupted([[https://openwrt.org/docs/guide-user/troubleshooting/vendor_specific_rescue|see Recovery Mode]])
  
-To recover: 
-  - Install [[http://www.wireshark.org|Wireshark]] on your computer. 
-  - Configure your computer with static IP 192.168.1.2 
-  - Connect your computer to a LAN port on the router. 
-  - Start Wireshark and monitor the LAN connection. 
-  - Powerup your router, when wireshark shows the first packet from 192.168.1.1 immediately press and hold the reset button on the back of the router for three seconds. 
-  - Router power LED should be flashing quickly. (Failsafe mode) 
-  - SSH via putty to "192.168.1.1" 
-  - at the Gargoyle prompt type ''firstboot'' 
-  - __wait__ until the command prompt returns 
-  - power cycle the router. 
-The router which should now come up in its default Gargoyle configuration and you will be able to [[getting_started|get started]] again. 
  
  
-Procedure for any firmware below 1.10.x 
  
-To recover: 
-  - Install [[http://www.wireshark.org|Wireshark]] on your computer. 
-  - Configure your computer with static IP 192.168.1.2 
-  - Connect your computer to a LAN port on the router. 
-  - Start Wireshark and monitor the LAN connection. 
-  - Powerup your router, when wireshark shows the first packet from 192.168.1.1 immediately press and hold the reset button on the back of the router for three seconds. 
-  - Router power LED should be flashing quickly. (Failsafe mode) 
-  - From a command prompt on your computer "telnet 192.168.1.1" 
-  - at the Gargoyle prompt type ''firstboot'' 
-  - __wait__ until the command prompt returns 
-  - power cycle the router. 
-The router which should now come up in its default Gargoyle configuration and you will be able to [[getting_started|get started]] again. 
  
  
-===== TFTP a new firmware image to your router ======== 
-If you router's power LED is flashing fast it means you are stuck in boot mode.  Configure your computer's ethernet port to a manual IP address of 192.168.1.2.  Then 'ping 192.168.1.1' if you get a response it means your bootloader will most likely accept a new image so get the appropriate image for your router.  For Broadcom routers you should get the ".bin" version rather than the ".trx" because the bootloader does not understand the ".trx" format.  Then TFTP the image to your router and wait.  The image transfers fast but it takes a few minutes for the bootloader to actually write the image you sent to flash.  Cycling power during this period will result in having to start all over.  When it is done it will reboot on its own. 
- 
-Here is an example 
-    D:\My Documents\Downloads>ping 192.168.1.1 
-    Pinging 192.168.1.1 with 32 bytes of data: 
-    Reply from 192.168.1.1: bytes=32 time=1ms TTL=100 
-    Reply from 192.168.1.1: bytes=32 time<1ms TTL=100 
-    Ping statistics for 192.168.1.1: 
-    Packets: Sent = 2, Received = 2, Lost = 0 (0% loss), 
-    Approximate round trip times in milli-seconds: 
-    Minimum = 0ms, Maximum = 1ms, Average = 0ms 
- 
-    D:\My Documents\Downloads>tftp -i 192.168.1.1 PUT gargoyle_1.4.1-wrt54g-squashfs.bin 
-    Transfer successful: 3346464 bytes in 6 seconds, 557744 bytes/s   
- 
-If you get this 
-    D:\My Documents\Downloads>tftp -i 192.168.1.1 PUT gargoyle_1.4.1-wrt54g-squashfs.trx 
-    Error on server : code pattern incorrect 
- 
-It means your bootloader does not understand the format of your image file.  Make sure you are using the correct one for your router and make sure you reboot before trying again.  I have noticed that the bootloader will only accept one TFTP attempt per boot. 
- 
- 
-===== JTAG recovery method ======== 
-If you cannot get either of the above to work for you then the next approach I use is the JTAG cable method.  This method requires that you purchase a cable on Ebay for $5 and solder a JTAG connector onto the motherboard of your router.  So you need to decide how much work you are willing to do for the cost of a new router.  I am not going to go into the details of this method since so much go info is already written about it at \\ 
-http://wiki.openwrt.org/doc/hardware/port.jtag \\ 
-http://sjoosten.nl/2013/07/unbrick-tl-wr1043nd.html 
failsafe_mode_recovery.txt · Last modified: 2019/04/28 09:55 by ispyisail