rsync can not rsync files with include filter...
use rsync to cp such files and dirs under /var/www/html/mydir directory
but these two files (/dir4/1.html /dir4/2.html) cant rsync to dest mechine.I still dont know why,,give me a hint?thx rsync configure file,below... [rsy_file_and_dir] comment= rsync some files and some dir path=/var/www/html/mydir read only= no include= file1 file2/dir1/*** /dir2/*** /dir3/*** /dir4/1.html /dir4/2.html exclude=* auth users=testuser |
I'm not sure if this is helpful or not. I had a similar problem. What I didn't realize was that the location of the include or exclude files is relative to where you run rsync from.
I wanted to rsync a whole system while excluding /tmp /home /dev /proc etc My exclude file looked like this: tmp/ home/ dev/ proc/ and I ran the rsync command out of / :) BinWondrin |
thx for your reply,i made my question clear now,
dir infomation: /var/www/html/mydir /var/www/html/mydir/(file1,file2) /var/www/html/mydir/dir1 /var/www/html/mydir/dir1/(file1,file2...fileN) /var/www/html/mydir/dir2 /var/www/html/mydir/dir2/(file1,file2...fileN) /var/www/html/mydir/dir3/ /var/www/html/mydir/dir3/(file1,file2...fileN) /var/www/html/mydir/dir4/ /var/www/html/mydir/dir4/(1.html,2.html) rsync configuration file /etc/rsyncd.conf content: and /var/www/html/mydir owner:testuser ------------------------------------- [rsy_file_and_dir] comment= rsync some files and some dir path=/var/www/html/mydir read only= no include= file1 file2/dir1/*** /dir2/*** /dir3/*** /dir4/1.html /dir4/2.html exclude=* auth users=testuser ------------------------------------ at other linux machine(local_linux),use following command to rysc ... # rsync -avzp testuser@remote_ip::rsy_file_and_dir /somewhere/somedir/ finally,,,, these two files /var/www/html/mydir/dir4/(1.html,2.html) cant rysc to local_linux.... !!...confuese...!! something wrong with /etc/rsyncd.conf ? but i still consist something wrong with exclude or include filter |
All times are GMT -5. The time now is 09:30 PM. |