question about why rsync log doesn't include remot ip or remote host

Chris Adams chris.a.adams at state.or.us
Tue Nov 22 16:40:58 MST 2011


Hello all,

This is my first post to this mailing list. I have been using rsync for a bit and have it mostly working the way I want.

I have a backup server that I run all scripts from. It rsyncs data from four different Linux servers via cron. A sample of a script is here:

rsync -avz --log-format="%t %b %f %l %M" --delete --stats -e "ssh -i /root/rsync/authors-rsync-key" backup at mydomain.com:/disk2/www /backup/seic37 2>&1 >> /var/log/rsync/rsync.log

This works fine and I get the log file entry that shows this:

2011/11/22 13:20:51 2089 acad0304/alllibdirstaff.MYI 2048 2011/08/31-12:46:20

I would like to include the IP and/or hostname of the machine being backed up, but when I use %a (remote IP) or %h (remote host) in the -log-format=, it just writes the literal %a or %h in those fields. Could this be because I am running scripts from the machine that is on the receiving end.

Inspire me. Thanks.


Christopher Adams
Library Systems Coordinator
Oregon State Library
chris.a.adams at state.or.us
503-378-5031
503-932-1004 (IT support)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.samba.org/pipermail/rsync/attachments/20111122/d063f7c5/attachment.html>


More information about the rsync mailing list