Re: Syncing from two sources to one target and deleting files not in either source

2020-07-23 Thread @lbutlr via rsync
On 21 Jul 2020, at 09:29, Joe via rsync wrote: > use ls or find to create a list of files on server 1 followed by a list > of files on server 2 > run it through sort -u to eliminate duplicates > use ls or find to make a list of files on ser This is basically what I am doing, though it is a lot mo

Re: Syncing from two sources to one target and deleting files not in either source

2020-07-21 Thread Wayne Davison via rsync
On Tue, Jul 21, 2020 at 4:15 AM @lbutlr wrote: > how can I remove files on Server 3 that do not exist on either Server 1 or > Server 2? > If you want rsync to do the deletions during a copy from one of the servers, you'll need a filter file of "protect" (P) rules for every dir and file on the oth

Re: Syncing from two sources to one target and deleting files not in either source

2020-07-21 Thread Joe via rsync
If there isn't a huge list of files, you could use a bash script: use ls or find to create a list of files on server 1 followed by a list of files on server 2 run it through sort -u to eliminate duplicates use ls or find to make a list of files on server 3 use diff to get lines only in server 3 (s