I authored a post on liberating a WNDR4700 router more than two years ago which garnered some interest in the community on developing a proper OpenWRT image. I’m happy to report that it finally happened! The LEDE (Linux Embedded Development Environment) team is fully supporting the apm821xx system-on-chip and are generating nightly firmware images for our use.
Instructions for installing LEDE on your WNDR4700/WNDR4720
- Read the following documentation: https://lede-project.org/docs/guide-quick-start/start
- Download the LEDE factory image firmware: https://downloads.lede-project.org/snap … actory.img
- Flash the LEDE factory image as a firmware upgrade using the router’s web interface.
- SSH in to install LuCI:
Everything should be working but USB and the SD Card reader. In order to get that working then:
- Download this binary firmware: uPD72020x-firmware_2_powerpc_464fp.ipk
- Install the above firmware using:
- Reboot and bask in the glory of your upgraded router!
Next up we’re going to install Debian
You will need to either add a USB flash stick or a physical hard drive into your WNDR4700 for this.
- Partition your drive to have a 1GB swap with the rest being ext4
- Log into the LuCI interface to mount the drives
- Head over to System > Mount Points
- Add the ext4 partition as a /mnt custom mount point
- Add the swap partition and activate it
- Next up we need to adjust Local Startup script. Head over to System > Startup and scroll down. Edit your local script to be similar to:
We will now install Debian with debootstrap while utilizing the LEDE kernel. Reference this material if you run into trouble.
- Install debootstrap:
- Install Debian using debootstrap:
- Chroot into Debian and prime it for use:
We already configured our rc.local under LEDE to chroot into /mnt/myinit on system reboot. This file will start all the necessary Debian services.
- Create this file under /myinit
If you reboot everything should now work and Debian should automatically start the services from /myinit too. I have also altered my LEDE environment to use SSH port 2222 and LuCI to use 8080 and 4443 as the ports. This allowed me to install SSH and nginx on Debian and use the standard ports. Good luck!