IoT data is valuable, and backing it up in a safe place is essential. To create a backup, it is important to save the files found in the metrics sub-directory and also the exCache.dat and mcjedi.dat files.
One of the easiest ways to do this is to archive them into a single file commonly referred to as a "zip" file. Open a terminal window on your Raspberry Pi. Change directory to where you installed JEDI One, In the example above, $ cd jedi. Now backup the JEDI One data to a single file, backup33.zip (call it anything you like with a .zip suffix) using the following command:
sudo python3 -m zipfile -c backup33.zip metrics/ exCache.dat mcjedi.dat
The / after metrics is important as it tells the utility to backup the whole metrics sub-directory. Depending on how much data you have acquired, this backup could include hundreds of files. You can test the zip file with this command:
sudo python3 -m zipfile -t backup33.zip
And if you are curious to see the actual contents of the zip file, they can be listed like this:
unzip -l backup33.zip
Now copy the ZIP file to a safe place on a backup drive, USB drive, DVD disc, SCP the file to another system, etc.
In Part 2 we will show you how to back this file up to cloud storage.