I am running OpenWrt on a Pi 4.
I just want to clarify my understanding of the difference between installing OpenWrt by way of Upgrading the firmware vs doing a Clean Install.
I am following these guides:
Upgrading OpenWrt firmware using LuCI and CLI
Sysupgrade – Technical Reference
OpenWrtScripts/opkgscript.sh
Raspberry Pi 4 OpenWrt Snapshot firmware
Here are my questions:
-
When I already have OpenWrt running on my Pi 4 can I upgrade to the latest snapshot firmware by installing rpi-4-ext4-sysupgrade.img.gz from LuCI Web Interface > System > Backup > Flash new firmware image?
-
Instead can I upgrade to rpi-4-ext4-sysupgrade.img.gz from the command line like this..
# syssupgrade -cf rpi-4-ext4-sysupgrade.img.gz
I'm not sure do I have that command correct? Would I need to unzip the archive first? Or maybe that's not even possible?
If I have a fully set up OpenWrt system then make a config file settings backup using: # sysupgrade -b /mnt/usb/settings-backup.tar.gz
and an installed packages list backup using: # sh opkgscript.sh write
which creates a list of packages in /etc/config/opkg.installed
- If I upgrade the firmware via 1. or 2. above will
/etc/config/opkg.installed
still exist so I can just restore that list of packages with# sh opkgscript.sh install
or do I need to copy over a list or a script output of the packages created earlier and saved to somewhere else?
Normally I have been installing and re-installing OpenWrt using a clean install method where I flash rpi-4-ext4-factory.img.gz to an SD card, put the card in the Pi 4 and then proceed with set up.
- If I start from a clean install then I guess I won't have the
/etc/config/opkg.installed
file to straightaway restore my list of installed packages... Instead I would have needed to run# sh opkgscript.sh script
beforehand and then copy over the install script it generates (as well as opkgscript.sh), run it and after that do a settings restore with# sysupgrade -r /mnt/usb/settings-backup.tar.gz
Have I got all that right?
Thank you!
Flex