Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Is it possible to specify multiple source directories in a duply configuration file? If not is there any simple workaround?

share|improve this question
add comment

2 Answers

up vote 2 down vote accepted

Make the source your system root SOURCE="/" and then create an exclude file at:

~/conf/<backupprofile>/exclude

At this article there is a good example of exclude file: http://aguslr.github.com/blog/2012/04/18/backups-with-duply/

**/*[Cc]ache*
**/*[Hh]istory*
**/*[Ss]ocket*
**/*[Tt]humb*
**/*[Tt]rash*
**/*[Bb]ackup
**/*.[Bb]ak
**/*[Dd]ump
**/*.[Ll]ock
**/*.log
**/*.part
**/*.[Tt]mp
**/*.[Tt]emp
**/*.swp
**/*~
**/.adobe
**/.cache
**/.dbus
**/.fonts
**/.gnupg/random_seed
**/.gvfs
**/.kvm
**/.local/share/icons
**/.macromedia
**/.obex
**/.rpmdb
**/.thumbnails
**/.VirtualBox
**/.wine
**/Downloads

Also, you should not backup /dev, /proc and other system folders in a Unix system. Just add them to the exclude file.

If you mean multiple remote directories, you must create a profile for each machine:

duply server1 backup
duply server2 backup
share|improve this answer
    
Why not an include filelist? –  student Mar 24 '13 at 18:58
    
Yes, that too. In my experience, for a full system backup is easier to create an exclude file. Maybe for a personal home backup you can pick each interesting directory "by hand" (What happens if you create a new directory and miss to add it to the list?). But when dealing with other users and services data you need to backup all except unusable stuff like devs and procs. –  n3storm Mar 25 '13 at 7:01
add comment

actually the above does merely achieve a backup everything while excluding some files/folders. the correct answer would be.

use the highest common root folder that contains all folder you want to back up. using SOURCE="/" is the easy way to achieve that.

now modify your .duply/<profile>/exclude as follows

+ /folder1
+ /folder2
- **

Note: there is a space between the plus/minus symbol and the path entry

this is because duply uses the globbing exclude list duplicity feature, where an exclude list merely treats each entry with a default '-' if not defined otherwise. see section 'File Selection' in the duplicity man page

http://duplicity.nongnu.org/duplicity.1.html#sect10

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.