Upgrade OpenWRT the Easy Way
It's important to keep your Router / Firewall appliances updated to the most recent versions of their firmware in order to maintain good security on your networks. With OpenWRT, for a long time, this was a tedious process. You had to get the new firmware, back up your existing setup, install the new firmware, install all of the packages you had again, and setup your configurations again.
It's been made much easier these days, but knowing how to get this done is not extremely obvious, as OpenWRT still does not "ship" with the necessary packages already installed.
Let's go through the process together to update your OpenWRT appliance, without having to reset everything manually.
What you'll need
- OpenWRT installed on something (x86, dedicated hardware)
- Access to the Luci Web Interface for the OpenWRT router
- Internet access
- About 10 minutes of your time.
Backup your current configuration
If you do nothing else in this tutorial, please, please, please make sure you make a backup of your current configuration and store it somewhere safe. This is important even if you aren't going to be updating the firmware today. This can save you hours of work should anything terrible happen to your router/firewall.
- Login to your router's web user interface.
- Go to 'System' in the top navigation. When hovering, it should display a drop-down menu.
- Select 'Backup / Flash Firmware' from the drop menu.
- On the Backup page, you'll want to click the blue button that says 'Generate Archive'.
- This will create a zipped file of your current configuration, and download it to your local machine.
- Rename this downloaded file by appending "-pre-update" to the end of the generated file name.
You now have a backup of your OpenWRT configuration.
Install the Attended Sysupgrade Packages
Now, we need to install a couple of packages from the software repository that will help us upgrade our current install, and also help us keep all of the configurations, packages, and so on in the process.
Upgrade your OpenWRT using Attended SysUpgrade
We can now update our OpenWRT system using the Attended Sysupgrade function we just installed. The good news is this function will be kept for us to use in the future since we are using it to upgrade our firmware in-place.
Congratulations, you've updated your OpenWRT system.
Make a Backup
I know what you're thinking, and yes, we did make a backup earlier, but that was our pre-upgrade backup. Now we need to make our post-upgrade backup. Make the backup in the same way as before, but rename this one by appending '-post-updade' to the file name. Keep both versions for a couple of weeks, just to be sure everything is working well. When you're satisfied that it's working fine, you can feel free to delete the pre-upgrade version if you want.
Support My Channel and Content
Support my Channel and ongoing efforts through Patreon:
https://www.patreon.com/awesomeopensource
Buy me a Beer / Coffee:
https://paypal.me/BrianMcGonagill