How can I upgrade to a new Pi (4), without losing ranking in the feeder stats and also retain data ?
Until now, any upgrades I have done, resets everything, is there any way to migrate preserving info. ?
How can I upgrade to a new Pi (4), without losing ranking in the feeder stats and also retain data ?
Until now, any upgrades I have done, resets everything, is there any way to migrate preserving info. ?
Create a new microSD card for your new Pi and then follow these instruction and all will continue uninterrupted.
S
Also see https://github.com/wiedehopf/graphs1090
Towards the bottom of the page there is a how to backup and restore graphs.
Read this before you re-image the original card.
Thank you for the tips
Add “piaware-config feeder-id (your ID)” at the bottom of /boot/piaware-config.txt, remove the SD-card from the old rpi, stick it in the new one, you’re good to go. You will find your feeder-ID on your FA feeder page under “Site information” as “Unique Identifier”.
===
If the old card is a regular SD, not a micro-SD, you’ll need to copy it sector-by-sector to a new micro-SD. You can also do this anyway, even if both cards are the same physical size, because it will allow you to keep both rpis as fallbacks to each-other. You will need an SD-to-USB adapter and a regular USB stick for this:
sudo su -
apt-get update
apt-get upgrade
nano /boot/piaware-config.txt
shutdown -h now
sudo su -
apt-get install dd
dmesg -w |grep sd:
dd if=/dev/sdX of=oldcard.img bs=4M status=progress
dmesg |grep sd
fdisk -l /dev/sdX
(that’s a minuscule L, not a digit one; the same applies also further down)mount /dev/sdXN /mnt
df -h
ls -lh oldcard.img
cp -va oldcard.img /mnt/
md5sum oldcard.img
md5sum /mnt/oldcard.img
shutdown -h now
sudo su -
apt-get install dd
dmesg |grep sd
mount /dev/sdXN /mnt
df -h
ls -l /mnt/
dmesg -w |grep sd
apt-get install dd
dd if=/mnt/oldcard.img of=/dev/sdY bs=4M status=progress
umount /mnt
fdisk /dev/sdY
p
Device Boot Start End Sectors Size Id Type
/dev/sdc1 8192 352900 344709 168.3M c W95 FAT32 (LBA)
/dev/sdc2 360448 30253055 29892608 14.3G 83 Linux
d
, give the correct partition number when asked and hit enter. Then press n
to create a new partition, say p
for primary when asked, and give the partition number and first sector exactly as they were before. When asked for the last sector, just press enter to accept the default. If you are asked anything about removing signatures, say no. Now press p
again to list the partitions and check the type of the new partition that you have just created. If it is not exactly the same as before, e.g. “83 Linux” or “c W95 FAT32 (LBA)” or whatever you had, press t
to toggle the type, give the correct partition number, then give the original code, e.g. 83, and press enter. Press p
again and compare what you have now to what you had originally. Everything should be exactly the same except the “End” sector, which should be a higher number than before. If that is the case, press w
to write the new partition table. If it is not, press q
to quit fdisk without making any changes, then start again on this point 13 when you have figured out what you did (or what I instructed) wrong.partprobe /dev/sdY
resize2fs /dev/sdYN
nano /etc/hostname
nano /etc/dhcpcd.conf
nano /etc/network/interfaces
All this might look terribly complicated at first sight, but it’s really nothing, just a bit of data copying back and fro so that you can get your new rpi up and running without having to install and configure everything from scratch, while also keeping your old rpi as a fallback in case you’d need it.
Having done 15, you will be able to boot both rpis at the same time. The one that happens to have the ADS-B dongle on it will feed data to FA. dump1090 on the other one will complain in the logs that it can’t find the dongle and exit, leaving the rpi and its CPU free for anything else you might want to use it for. Just don’t run both rpis at the same time with ADS-B dongles and antennas on both of them.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.