Public bug reported:

Between Ubuntu 8.04 and 8.10 the rsnapshot package was updated.  The new
version has a couple of problems in the default /etc/rsnapshot.conf file
included in the package.  These problems did not exist in 8.04.

The following configuration options are all located in
/etc/rsnapshot.conf.

Problem 1: snapshot_root is wrong

In 8.04, the top-level destination dir snapshot_root is there and is configured 
correctly: 
der...@dev:~$ cat /etc/rsnapshot.conf | grep snapshot_root | head -1
snapshot_root     /var/cache/rsnapshot/
der...@dev:~$ ls -lad /var/cache/rsnapshot
drwxr-xr-x 2 root root 4096 2006-06-21 23:46 /var/cache/rsnapshot
der...@dev:~$ 

Note, the value for "snapshot_root" is "/var/cache/rsnapshot", which is
correct.  That dir is created by the DEB at install time, and it's owned
by user root.

In 8.10, this is now /.snapshots/, which does not exist, and which is
not created by the DEB:

r...@ubuntu:/etc# cat /etc/rsnapshot.conf | grep snapshot_root | head -1
snapshot_root   /.snapshots/
r...@ubuntu:/etc# ls -lad /.snapshots
ls: cannot access /.snapshots: No such file or directory
r...@ubuntu:/etc# ls -lad /var/cache/rsnapshot
drwx------ 2 root root 4096 2008-05-06 07:36 /var/cache/rsnapshot
r...@ubuntu:/etc# 

Note that the wrong value "/.snapshots" does not exist on the
filesystem.  If Ubuntu wants to change the default from
/var/cache/rsnapshot to /.snapshots then the package should create that
dir at install time and no longer create /var/cache/rsnapshot.  As an
Ubuntu rsnapshot user, my preference would be to just revert the default
config file back to the way it was in 8.04.

Problem 2: The intervals are uncommented (danger!)

In 8.04, the cron job interval definitions were all commented out by
default:

der...@dev:~$ cat /etc/rsnapshot.conf | grep "#interval"
#interval       hourly  6
#interval       daily   7
#interval       weekly  4
#interval       monthly 6
der...@dev:~$ 

The leading "#" is a comment, like Python/Bash/etc.  This had the effect
that the user was forced to edit the config file and define the
intervals that he wanted.

In 8.10, the intervals are uncommented:

r...@ubuntu:/etc# cat /etc/rsnapshot.conf | grep "^interval"
interval        hourly  6
interval        daily   7
interval        weekly  4
r...@ubuntu:/etc# 

This means simply running rsnapshot after an install (without
customizing the config file) will cause rsnapshot to backup the local
directories /home/, /etc/, and /usr/local/, because those local backup
targets are defined (by default) at the end of the config file.  In my
opinion that is dangerous.

I use rsnapshot to do networked-based backups across an SSH tunnel.
We're talking terabytes of data.  If I did an rsnapshot install and it
backed up my /home/ dir to the local dir /.snapshots/ I would
immediately run out of disk space.

Since rsnapshot is a backup program providing networked backups with
incremental file changes, I think the user should be forced to define
his preferred backup targets and intervals.  Presuming /home/ (or any
other dir) is the target to be backed up is a Bad Idea.  I'm a huge fan
of It Just Works (and I'm a total Ubuntu fanboy) but in this case I
think the user should be forced to intervene and hand-edit the config
file -- which is exactly how 8.04 worked.

Extra Question: Is it possible to add regression tests to the package
build process, to prove these problems are not re-introduced again in
9.04 (and upwards)?

** Affects: rsnapshot (Ubuntu)
     Importance: Undecided
         Status: New

-- 
rsnapshot conf file broken in new 8.10 package
https://bugs.launchpad.net/bugs/318577
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to