FlightAware Discussions

What gets overwritten when upgrading PiAware?

I use the excellent OL3 on a couple of PiAware boxes in the UK. I also have some tweaks to various files, some scripts and some cron jobs. These PiAware boxes are using PiAware SD card images.

OL3 is a complete replacement for /usr/share/dump1090-fa/html. I rename the standard one as html-original.

If a new version of PiAware comes out and I use “Upgrade and restart PiAware” from the stats page, the OL3 html is wiped out with the standard html from the new PiAware version and the various tweaks are also lost. That’s no problem and is what I would expect.

So I’d like to store backups of the OL3 html (a point in time tar.gz), the scripts and notes about the tweaks somewhere safe on the SD card. That way it’s easy to quickly redeploy them from the Pi locally after such an upgrade.

I’d like to know please, what gets wiped or overwritten when doing this kind of upgrade, or, conversely, where is a safe place to store backups and notes? Is /home/pi left alone? What about /usr/local/bin and /opt? Is crontab rewritten?

I searched for a while trying to find if this had been covered but didn’t find anything so any definitive info would be appreciated.


Generally, all updates are handled by dpkg and try to follow the usual Debian rules. Non-config package-owned files may be overwritten without warning. Config files in /etc will only be changed if they have not had user modifications. Nothing in /usr/local or /opt is touched.

There are also occasionally upgrade tasks that get run e.g. if there are changes to config formats and so on, but generally those will be very conservative about what they change in user-modified files. (for example, see https://github.com/flightaware/piaware-support/blob/master/debian/piaware-support.postinst)

For an exhaustive list of the package-owned files, try dpkg -L <package name> (main packages are piaware, dump1090-fa, and for sdcard images piaware-support, piaware-release). Conffiles are listed in /var/lib/dpkg/info/<packagename>.conffiles

1 Like

Just use another folder for the html and configure it with lighttpd to be available via /alk or something.

I never understood why the instructions overwrite the dump1090-fa html folder when it’s not really too complicated to do a separate URL and folder.

I suppose i could make an install script for the alkissack stuff easily enough.

Thanks, this should help others looking for the same info in future too. Based on this my approach will be to store mods and notes in /home/pi so they are safe from upgrades and can be redeployed if needed. If the upgrade overwrites something it’s easy to redeploy from there. If it’s too messed up down the line then it’s easy to grab the lot from home (it’s simple to copy the backup into /boot and grab from the computer before reimaging) and reimage with a clean install.

Because that takes something which is currently very straightforward with a minor problem that is trivially managed, and turns it into something else that isn’t as straightforward, doesn’t consider the typical use case for OL3, and introduces new problems of its own.