--delete not working when files are pushed to rsync daemon
john at gngsta.com
john at gngsta.com
Wed Aug 20 22:03:34 EST 2003
Hi. I've been having a frustrating problem with rsync that I'm looking
for advice on.
My goal is to syncronize a set of servers with the same libraries,
binaries, and main configuration files without touching the unique data
that exists on the indivudual servers. My --exclude-from file is rather
extensive but it works great when pulling from a daemon. I'm able to
start an rsync daemon on any of the indivudual servers and pull the
system libraries and binaries to a test box without pulling the unique
data on the server.
As I'm trying to move this into production, I've started rsync daemons
on the individual servers, and then on my build server, I run an rsync
in dry-run mode to push /platform out to one of the servers. Any new
or modified files are noticed by the rsync daemon and would be pushed
out, but even though I'm using --delete, files "that don't exist on the
sending side" are not deleted.
My rsyncd.conf on the individual servers is simple:
path = /
use chroot = no
read only = no
uid = root
gid = root
hosts allow = n.n.n.n/m
The command line I use when pushing is slightly longer:
build# rsync -a -vvv -n --delete --exclude-from rsync.excludes /platform/ individual.server::platform
As I mentioned, this works great for new files and modified files. If
/platform/etc/dir and /platform/etc/dir/file are created on the build
server, /etc/dir and /etc/dir/file will be created on the individual
server. However, if /etc/dir/tmp is created on an invididual server, the
next rsync push from the build server will NOT list it as marked for
deletion, even when using --delete.
Does --delete only work when *pulling* from a server? If so, do I have
any options for doing what I'm trying to do without running a daemon on
the build server and pulling from the individual servers?
If any of this is unclear, please let me know and I'll be more than
happy to clarify. Thanks very much for any assistance.
More information about the rsync