Traffic Totals backup how?
-
@error_account The data used by traffic totals is created by vnstat. vnstat stores it data in a database located at /var/db/vnstat/vnstat.db
I'm not sure the best way to backup a specific file. There is a Backup package, but I have not used it.
-
@traveller Thank You, so isn't there a "built-in" backup solution for this problem (include the "extra data" option in the Backup & Restore)?
-
@error_account Not that I know. However, I only recently started with pfSense, so that can be very little at times.
-
@traveller I get a bit closer so Thank You :)
-
@error_account Your best bet is to backup the DB (/var/db/vnstat/vnstat.db) and copy it over to your new install. I just did this yesterday and it worked like a charm. If you're custom to Windows, WinSCP is your friend.
-
@cino said in Traffic Totals backup how?:
@error_account Your best bet is to backup the DB (/var/db/vnstat/vnstat.db) and copy it over to your new install. I just did this yesterday and it worked like a charm. If you're custom to Windows, WinSCP is your friend.
I got one for you. Probably like most here I recently updated to 2.5, I think I started with 2.4.4 and did the subsequent updates. I have limited knowledge so when doing the prior updates I read that all packages should be uninstalled when updating. I removed my packages updated to 2.5 and reinstalled my packages but lost all my previous Traffic Totals history.
Based on your post (and if I would have seen this before updating) I should have copied off the vnstat.db first. With Status-Traffic-Totals uninstalled there is no /var/db/vnstat/vnstat.db location, with it reinstalled its totals are new going forward with all past history gone. I searched with WinSCP for an old or backup copy of vnstat.db and none to be found. Does that sound about right?
TIA
-
@s762 I'm guessing when you manually uninstalled the packages, it removed the DB with it :-(
-
@cino yes, like it was never there. oh well live & learn. Thanks for the post, I'll be on top of it next time
-
@cino Thank You :)
@s762 I didn't saw this "uninstall-update-reinstall" procedure before so thank you for the tip :)
I just wanted to try some modifications (for testing) in the pfsense settings and I wanted to make a backup for when I'm finished just restore to the original state, and after this restore I saw all stats are gone :( -
@cino
I repeated the process today to upgrade from 2.5 to 2.5.1 RC but this time I made a copy of vnstat.db and replaced the newly created DB and all went well. Thanks again for the info