Results 1 to 2 of 2
fI execute the following rsync command at the console (as root), it works perfectly:
PHP Code:
rsync - av -- delete -- progress -- bwlimit = 5000 -- exclude =/ ...
- 01-30-2009 #1
rsync puzzle
fI execute the following rsync command at the console (as root), it works perfectly:
HOWEVER, if I execute it within a script, it copies the files into the folder where I execute the script, instead of to the other boxPHP Code:rsync -av --delete --progress --bwlimit=5000 --exclude=/srv/www/htdocs/squirrel* /srv/www/htdocs/* 198.60.1.5:/srv/www/htdocs/
Any ideas as to why it does this? I am adding more lines than this to my "backup script", but this is the simplified version. Very puzzling to me as to why it copies the files locally instead of across the wire to the new box.PHP Code:
#!/bin/bash
RSYNC_PASSWORD=mySecret
TMPFILE='/var/log/rs_transfer.txt'
RHOST="198.60.1.5"
#rsync -av --delete --progress --bwlimit=5000 $RHOST: >> $TMPFILE 2>&1
rsync -av --delete --progress --bwlimit=5000 --exclude=/srv/www/htdocs/squirrel* /srv/www/htdocs/* $RHOST:/srv/www/htdocs/
- 01-30-2009 #2
Well, I found out a way around it. I had to place every command in ` (back ticks). Not sure why, but it is working now other than my RSYNC_PASSWORD part.


Reply With Quote