exclude problem

Lars Nordin lnordin at noblesys.com
Mon Mar 21 21:03:57 GMT 2005


I have looked on the mailing lists and through rsync documentation but those 
still haven't solved my problem. I may be calling rsync incorrectly but the 
problem I have is that the exclude file seems to be ignored. My final goal is 
to replicate an entire host, excluding some files that contain specific IP, 
hostname configuration things. I'm trying to start small by mirroring a 
directory first and then later I will just specify "/". I'm running rsync on 
the destination so that my rsync configuration is on that box but may be I 
should switch it?


Here is the command line I'm using.

rsync -avv -n --delete --exclude-from=sys_dont_replicate.list -e ssh 
root at patron:/etc/ /etc

here is some sample output
=====================
opening connection using ssh -l root patron rsync --server --sender 
-vvnlogDtpr
--delete . /etc/
receiving file list ...
expand file_list to 4000 bytes, did move
expand file_list to 8000 bytes, did move
expand file_list to 8000 bytes, did move
done
expand file_list to 4000 bytes, did move
expand file_list to 8000 bytes, did move
done
deleting in .
deleting cron.d/replication
.java/.systemPrefs/.systemRootModFile
adjtime
aliases.db
cron.d/webmin_update
fstab
fstab.REVOKE
hosts
ioctl.save
kde/kdm/kdmsts
lilo.conf
mail/statistics
modules.conf
motd
mtab
ntp/drift
printcap
printcap.old
resolv.conf
samba/secrets.tdb
shadow
sudoers
sysconfig/hwconf
sysconfig/network
sysconfig/network-scripts/ifcfg-eth0
sysconfig/network-scripts/ifcfg-eth1
total: matches=0  tag_hits=0  false_alarms=0 data=0
wrote 382 bytes  read 39763 bytes  80290.00 bytes/sec
total size is 4450769  speedup is 110.87



exclude file sys_dont_replicate.list
========================
/etc/cron.d/replication
/etc/hosts
/etc/lilo.conf
/etc/motd
/etc/ssh/*
/etc/sysconfig/hwconf
/etc/sysconfig/network
/etc/sysconfig/network-scripts/ifcfg-eth0
/proc/*
/replication/*
/root/.bash_profile
/root/.ssh/*
/tmp/*
/usr/backup/*
/var/log/*

rsync  version 2.5.4  protocol version 26
Running on RH v7.3



More information about the rsync mailing list