Bug #4773
closed
Configuration backup - "Do not backup RRD data" is broken
Added by Kill Bill almost 9 years ago.
Updated over 8 years ago.
Category:
Backup / Restore
Affected Architecture:
All
Description
This worked just fine before the latest batch of commits (i.e., a week ago, or even less).
- I have the "Do not backup RRD data" checkbox pre-ticked, but the downloaded config.xml contains all the RRD data.
- When I untick it, I get the RRD data twice, as a bonus. (Not keen on checking how restore of such broken backup works, frankly.)
Ref.: https://forum.pfsense.org/index.php?topic=95306.0
On nanoBSD 32-bit running snap from Wed Jun 17 18:54:23 I can't replicate this. With the box checked I get an ordinary small config. With the box unchecked I get a single large <rrddata> section after the ordinary config with about 3MB of stuff in it.
This is a full install. With the box, I get ~4 MB with huge <rrddata>; without the box, it's ~8 MB with two <rrddata> sections - one directly after another.
2.2.3-DEVELOPMENT (amd64)
built on Sun Jun 14 19:59:54 CDT 2015
FreeBSD 10.1-RELEASE-p12
With the "do not backup" ticked i get an 21,6 kb file and if i untick it I get a 1,7mb file. If i tick it back on I the 21,6 kb file.
This is on a full install so i cant reproduce this either.
Well, the problem apparently is this:
$ ls -la /cf/conf/config.xml
-rw-r--r-- 1 root wheel 4292644 Jun 18 09:30 /cf/conf/config.xml
$ grep rrddata /cf/conf/config.xml | egrep -v rrddatafile
<rrddata>
</rrddata>
This is a box which was freshly installed and the config.xml restored to it from a backup which was including the RRD data.
Hmmm - I guess on restoring from a backup that has RRD data, the system should remove existing RRD data files, build a new set from the RRD data in the config, then remove the RRD data from config.xml
- Status changed from New to Feedback
The current code does unset and the code to unset has been in place for ages (3+ years). See source:usr/local/www/diag_backup.php#L396
I can't reproduce this on a current snapshot. I restored a config with RRD data inside and the data was put back into RRD files and the config.xml did not contain the rrddata tag after.
Are you certain the configuration was restored via diag_backup.php and not some other way?
- Target version deleted (
2.2.3)
can't replicate that here either, and that code hasn't changed in quite some time. will leave for feedback for now.
- Status changed from Feedback to Closed
- Affected Version deleted (
2.2.3)
Also available in: Atom
PDF