Re-flashing from custom install of OpenWRT

I have acquired a collection of Linksys WRT54GL routers to use as wireless bridges – with only one seemingly small task to do – reflash them with a firmware of my choice. Easy, I thought!

It turns out that the routers had a custom firmware on, that even after a 30/30/30 reset, they didn’t allow the facility to flash the firmware through the UI.

OpenWRT no support for flash firmware

Most interaction had to be done through the command line – here is the procedure I followed:

  1. 1. Perform 30/30/30 reset as described here.
  2. When the router is booting up after only a second or two, repeatedly press the Cisco Systems button on the front – for several seconds. This will enable Failsafe mode.
  3. Telnet into the router (after having manually set your IP address to (If this doesn’t work you probably aren’t in Failsafe mode).
  4. Run “firstboot”.
  5. Reset the root password with “passwd”.
  6. Reboot “reboot -f”.
  7. When the router reboots, you can connect with ssh with the root user, and the password specified previously. From here you can transfer the bin file and flash (as described here or below).
  8. Use scp to transfer the bin file to the temp file system. “scp ~/Downloads/dd-wrt.v24_mini_generic.bin root@”.
  9. Log in to router with ssh, and change into the /tmp/ directory.
  10. Rename the file, to make it a trx. “mv dd-wrt.v24_mini_generic.bin dd-wrt.v24_mini_generic.trx”.
  11. Write to linux fs and reboot “mtd write dd-wrt.v24_mini_generic.trx linux && reboot”.
  12. The router will now boot back up in dd-wrt. Yay!


One thought on “Re-flashing from custom install of OpenWRT

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>