On Thu, Jan 12, 2006 at 01:26:32PM +0100, Paco Rosich wrote: > Seems to me that this could be done with a new server option > (--forced-options???) to force the --backup thing to be done, so the > rsync server never completely destroys any data it has stored.
This is possible using the latest CVS source using the "pre-exfer exec" server option with a custom script/command. You would make the script examine the RSYNC_ARG# values (e.g. RSYNC_ARG1) and verify that the 'b' option was included in the short-option letters, that the --backup-dir option was present, and that the arg right after --backup-dir was the expected directory string. If they were not, it would simply need to exit with an error status and rsync would abort the transfer. As an example, these RSYNC_ARG# variables might be present: SYNC_ARG0=rsyncd RSYNC_ARG1=--server RSYNC_ARG2=--sender RSYNC_ARG3=-vblogDtpr RSYNC_ARG4=--list-only RSYNC_ARG5=--backup-dir RSYNC_ARG6=/backup/here RSYNC_ARG7=. Note that $RSYNC_ARG3 contains the 'b' (--backup) option. ..wayne.. -- To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html