I have a simple script that sends one file to two locations on the same destination server. Here's the code: DEST="remotehost" SRC="/home/boss/application.conf" DST1="/home/user1/application.conf" DST2="/home/user2/application.conf" RSYNC1=`rsync -caW -e ssh $SRC $DEST:$DST1` RSYNC2=`rsync -caW -e ssh $SRC $DEST:$DST2` This runs every 5 minutes. What I'm seeing is the first location occasionally gets a *partial* file, but the second location never has a problem. There does not appear to be any obvious correlation to why this would be happening. I have never witnessed the problem when running the script by hand to try and duplicate, witness any error output, etc. Any idea how to troubleshoot? Or how I can get rsync to verify the file has been transferred without error? A more reliable alternative than using rsync for this situation? Thanks, Scott
I just realized that "application.conf" is an automatically generated file, and I think it might be running around the same time as the replication script. Perhaps my replication script and the auto-generation script are occasionally running at the exact same time, thus causing the replication script to not have a complete file to transmit. I'm staggering the replication script to see if that solves the problem. Thanks, Scott On Nov 14, 2007 3:45 PM, Scott Moseman <scmoseman at gmail.com> wrote:> > I have a simple script that sends one file to two locations on the > same destination server. Here's the code: > > DEST="remotehost" > SRC="/home/boss/application.conf" > DST1="/home/user1/application.conf" > DST2="/home/user2/application.conf" > RSYNC1=`rsync -caW -e ssh $SRC $DEST:$DST1` > RSYNC2=`rsync -caW -e ssh $SRC $DEST:$DST2` > > This runs every 5 minutes. What I'm seeing is the first location > occasionally gets a *partial* file, but the second location never has > a problem. There does not appear to be any obvious correlation to why > this would be happening. I have never witnessed the problem when > running the script by hand to try and duplicate, witness any error > output, etc. > > Any idea how to troubleshoot? Or how I can get rsync to verify the > file has been transferred without error? A more reliable alternative > than using rsync for this situation? > > Thanks, > Scott >
Scott Moseman wrote:> I have a simple script that sends one file to two locations on the > same destination server. Here's the code: > > DEST="remotehost" > SRC="/home/boss/application.conf" > DST1="/home/user1/application.conf" > DST2="/home/user2/application.conf" > RSYNC1=`rsync -caW -e ssh $SRC $DEST:$DST1` > RSYNC2=`rsync -caW -e ssh $SRC $DEST:$DST2` > > This runs every 5 minutes. What I'm seeing is the first location > occasionally gets a *partial* file, but the second location never has > a problem. There does not appear to be any obvious correlation to why > this would be happening. I have never witnessed the problem when > running the script by hand to try and duplicate, witness any error > output, etc. > > Any idea how to troubleshoot? Or how I can get rsync to verify the > file has been transferred without error? A more reliable alternative > than using rsync for this situation? > > Thanks, > Scott > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centos >Scott, also, instead of running rsync twice between local & remote host, you may want to run it once between local & remote and once between the two remote host locations. Or even just do a ssh $DEST cp $DST1 $DST2 as a conf file will be small anyway. Yiorgos
Apparently Analagous Threads
- How to "Dinamyc NAT"
- RFC: [GlobalISel] Towards a generic MI combiner framework
- RFC: [GlobalISel] Towards a generic MI combiner framework
- [LLVMdev] Initial thoughts on an LLVM backend for N-address generic assembly
- Resend: assertion in MachineCopyPropagation::isNopCopy