I am trying to change our backup strategy from one where we include only certain directories and exclude everything else to a blanket include and a list of excluded files and/or directories.
I am pulling files from an rsync 2.6.9 daemon with the following command:
rsync -avrH --numeric-ids --ignore-errors --delete --delete-excluded --stats
--filter=". mergelist.dat" remoteservername::modulename /localbackupdir
The issue at hand is this:
I want to include certain files (hopefully with a wildcard) from the remote
server in a directory called /scratch2/prod_dp_exports/ but exclude any other
files or directories recursively starting at /scratch2/
I also want to include everything else (/) from the remote server except for a
few directories/mountpoints that I will also be specifying (/proc/*, /sys/*,
etc.)
I have played with --files-from, --include-from and --exclude-from as well as
the --filter included in the command above, but I can't seem to make this
happen.
An example of the filter file I've been trying to get working:
+ /
+ /scratch2/prod_dp_exports/FULL*
- /scratch2/*
- /proc/*
- /sys/*
- /dev/*
I seem to have much better luck with the reverse logic, meaning including only
what I want and adding a "- *" to the end of my filter file.
Any thoughts/comments/flames would be greatly appreciated.
Best regards,
Sterling Windmill
Sterling Windmill
Systems and Technology
Phone: 586-752-9671 Ext 161
Fax: 586-752-6589
www.custdata.com
CONFIDENTIALITY NOTICE: This email contains information from the sender that
may be CONFIDENTIAL, LEGALLY PRIVILEGED, PROPRIETARY or otherwise protected
from disclosure. This email is intended for use only by the person or entity to
whom it is addressed. If you are not the intended recipient, any use,
disclosure, copying, distribution, printing, or any action taken in reliance on
the contents of this email, is strictly prohibited. If you received this email
in error, please contact the sending party by replying in an email to the
sender, delete the email from your computer system and shred any paper copies
of the email you printed. <<LOGO.gif>>
-- To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
