--force restore to / removes everything

Bug #577342 reported by Greywolf
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Duplicity
Fix Released
Undecided
Unassigned

Bug Description

Duplicity version 0.6.06
Python version 2.3.4 (#1, Aug 8 2009, 09:59:27)
[GCC 4.3.6 20060404 (Red Hat 3.4.6-11)] on linux2
Linux 2.6.9-89.0.19.ELxenU (CentOS 4.8 (Final))
Filesystem target type: ext3
No log, sorry.

If you run

 duplicity restore \
     --force \
     --file-to-restore some/path \
     proto://user@host/path /

 duplicity will gleefully begin removing everything from / on down
 in order to ensure that it can restore some/path. I found this
 out the hard way when I went to restore into /, and watched it
 take out /bin, /boot, /dev, /etc and part of /home before starting
 to belch forth godawful messages complaining about something
 going egregiously wrong.

 I was not pleased.

 I will argue that this behaviour is insane. if I'm doing a selective
 restore, it should only be deleting things that I am restoring, not
 restoring a full snapshot (maybe have a --snapshot or something option)
 as though that file were the only thing there to start with.

Changed in duplicity:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.