I'm a beginner with rsync. I have a file "filelist.txt" with some files with full path :
/tmp/folder1/file.txt
/tmp/folder2/file.txt
/tmp/folder2/file.txt
I want to copy this files from the server A to serveur B, and create directories if it's needed. This file can evolve several time a day, so I don't want to handle dir creation manually on the other server before transfert files.
So I used :
cat filelist.txt | xargs -I {} rsync -r {} admin@ttt.i-test.fr:{}
But I have for each line :
rsync: change_dir#3 "/tmp/folder1" failed: No such file or directory (2)
rsync error: errors selecting input/output files, dirs (code 3) at main.c(632) [receiver=3.0.3]
rsync: connection unexpectedly closed (8 bytes received so far) [sender]
What I'm doing wrong ?