Include / exclude patterns
maxb at ukf.net
Thu Nov 28 16:52:01 EST 2002
Carlos Molina <cmolina at net-uno.net> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> I'm trying to make some backups using rsync, but I have some questions
> about it.
> First, on the receiving side, i make a test with this line.
> rsync -vv -e ssh --recursive --include-from=include.txt
> cmolina at www-01:/ /tmp/cmolina
> On include.txt I have.
> + etc
> + home/cmolina/source
> + home/cmolina
> + var/spool
> - - dev/
> - - home/cmolina/
> - - tmp/
> - - root/
> - - disk2/
> - - home/
> - - usr/
> - - lib/
> - - var/
> - - bin/
> - - boot/
> - - dev/
> - - etc/
> - - floppy/
> - - initrd/
> - - lost+found
> - - proc/
> - - opt/
> - - sbin/
> - - vmlinuz
> - - /*
What are you tring to do with the double - signs?
> Note that the source path is /.
> Well, in resume, I'm trying to bypass the default rsync selection
> mechanism (include all the objects that aren't specified on the list),
> because we want to deny (exclude) all filenames, directories,
> archives, etc, and only permit the files, directories,
> SUBDIRECTORIES, that we specify on a include file.
> For example, we want to exclude anything, and only include the
> following directories (and it's contents)
If you want everything under /home/cmolina, why is /home/cmolina/source also
in your list?
More information about the rsync