Opkg upgrade vs. flashing sysupgrade


I have a general question.

When do I have to flash a sysupgrade.bin (and potentially loose all my settings)?

As far as I understand, using "opkg list-upgradable | cut -f 1 -d ' ' | xargs opkg upgrade" if new versions are available should keep me up to date.

But what about releases like 19.07.1 --> 19.07.2 ? Do I have to flash a sysupgrade.bin or is "opkg upgrade" still OK?

Greetings from Germany


Always flash a new version. In most cases, you can preserve settings when running an upgrade for point revisions (I.e. 19.07.1 > 19.07.2). You can make a backup first, too. You will need to reinstall packages, but that is fairly easy and there are some scripts available to help automate that process.

Never, ever use opkg upgrade - this method will likely cause you major problems and does not actually upgrade the version. Some people will say that they have used opkg upgrade successfully, but for every one of those people, there are many more who have problems caused entirely by that process - some minor, some major. Just don’t do it (search the forums for more detail if you need or don’t believe me).


Well, then I have a few questions:

a) Why is there "opkg upgrade" in the first place if you will destroy your installation?

b) Why is there no "user friendly" upgrade script already integrated into OpenWrt? I have only a few packages installed (p910nd, SQM QoS, Adblock) but reinstalling and especially configurating those (and my Static Leases) Each. Time. Again. Is really painful and time consuming.

For someone who isn't a Linux Pro, this kinda sucks...
(But thanks for your reply!)


It an be used to selectively upgrade individual packages.

sysupgrade is rather complex due to the limited flash space in many routers. OpenWrt supports hundreds of different router models, and they have widely different flash structures and update methods. Quite different that "let's update Linux in x86 PC with unlimited storage space".

Note that you can preserve your settings in sysupgrade, so there should be no reason to reconfig static lease etc. But you need to re-install the packages.

1 Like