OpenWrt: Upgrading OpenWrt to the latest snapshot build

Although stables releases of OpenWrt come out every 6 to 12 months, the automatically built snapshots offer a way to embrace the latest features, patches, and  security fixes without waiting that long.

A sysupgrade procedure works by saving the configuration files from known locations, deleting the entire filesystem, installing the new version of OpenWrt,  and then restoring the configuration files.

This is usually painless, but there can be issues if configuration changes have been made in non-standard file locations and are not saved.  Additionally, custom packages do not survive the sysupgrade and have to be reinstalled (to ensure compatibility with the kernel) and their new configurations must be manually merged.

Continue reading “OpenWrt: Upgrading OpenWrt to the latest snapshot build”

OpenWrt: Flashing Linksys WRT1X00AC/S from USB-TTL Using Ubuntu

openwrt_logoFlashing the firmware of the Linksys WRT1X00AC/S is well documented on the OpenWrt wiki.  So I don’t feel the need to go over the architectural concepts in this article, but I did want to provide instructions for the Ubuntu specific tools you can use to flash the firmware.

If you want to try flashing to OpenWrt using the factory LinkSys ‘Router Firmware Update’ feature, that is your choice, but it really is working blind and you have no ability to fix issues if something goes wrong.  After bricking my router once, I now rely solely on the Serial to USB-TTL cable which is the highly recommended connectivity method from the OpenWrt page.

Step 1. Connect via USB-TTL cable

I wrote a detailed article about using the Adafruit USB TTL Serial cable to connect to the Linksys WRT1X00AC/S for an Ubuntu host.

After powering off/on the router, you should be able to clearly the see the boot sequence of your Linksys firmware in your terminal program.  Below is a snippet of the output showing the Linksys logo in ASCII art which scrolls by as the router brings up all its services.

linksys_factor_booting2

Continue reading “OpenWrt: Flashing Linksys WRT1X00AC/S from USB-TTL Using Ubuntu”

OpenWrt: Installing a TFTP Server on Ubuntu for OpenWrt Firmware Updates

openwrt_logoThe Trivial File Transfer Protocol (TFTP) is an extremely simple protocol most often used for network booting strategies, such as PXE and flashing OpenWrt images unto consumer routers.

I go over full instructions for flashing OpenWrt using Ubuntu and flashing a sysupgrade in another post, this article will focus specifically on setting up a tftp server daemon on Ubuntu that can be used to serve the binary image file.

Installation

First, install the tftp server and client packages:

# apt-get install tftpd-hpa tftp-hpa -y

Continue reading “OpenWrt: Installing a TFTP Server on Ubuntu for OpenWrt Firmware Updates”

OpenWrt: Use setenv firmwareName for newer versions of Linksys WRT1900AC/S

openwrt_logoWhen flashing an OpenWrt image to your newer versioned WRT1900AC/S, be aware that instead of using ‘setenv firmware_name’, you should instead use ‘setenv firmwareName’.

The command will not fail, but the router will not understand that it should look for a non-default name for the image and your tftp transfer will fail.

This change appears to have been made between WRT1900AC V1 and WRT1900AC V2.  So, for the latest versions such as WRT1900ACS, be sure to use ‘setenv firmwareName’.

Ubuntu: Serial level access to your Linksys WRT1X00AC/S

ubuntuWhether you are updating the official LinkSys router firmware or taking it a step further and installing open-source firware like OpenWrt, serial level access to your Linksys router is the most dependable way of guaranteeing a connection.

And if you have tried to flash the firmware via the web admin interface and after a reboot you cannot get web access again, then you have no choice.  You have to be able to plug directly into the router’s serial interface and troubleshoot.

Continue reading “Ubuntu: Serial level access to your Linksys WRT1X00AC/S”