22 Марта, 2012

How to restore OpenWRT router

Now you have your OpenWRT router broken and it has turned to a "brick" no worries! Assume you have entered the OpenWRT failsafe mode. The host is responding to the telnet and allows you to log in without passwords. The next step is to restore to the original firmware or previous version of OpenWRT.
Please note that you might need to run a local http-server in order to continue I would like to recommend you the Small HTTP server ver 3.05 for Windows be sure to have Putty in place and ready.
The main idea is to upload the firmware you need into the router and flash it from there directly, but we don't have access to the internet only to LAN that's why we need to start a http-server and put the firmware we want to back to in the root of that server. Enable the server before doing the restoration procedure and make sure it's working at port 80.
Restoration procedure:
1. Telnet to the on port 23
2. cd /tmp
3. wget
(assume your PC you are fashing the router from is having the address and firmware.bin is the file you want to flash it with).
In the next step the router should upload the firmware we want to the /tmp directory of your router. If that works the next command will be:

4. mtd -r write /tmp/firmware.bin firmware
You'll see something like: Rebooting... and in a few moments your router will be alive again. Now open the web-interface at it works!
© 2012 Denis I. Zabiyako
comments powered by Disqus