rsync is a tool to efficiently copy directory hierarchies, locally or remotely, with powerful filters to decide what gets copied.
18
votes
7answers
11k views
Rsync filter: copying one pattern only
I am trying to create a directory that will house all and only my PDFs compiled from LaTeX. I like keeping each project in a separate folder, all housed in a big folder called LaTeX. So I tried ...
4
votes
2answers
270 views
How to use rsync with a remote remote host
I am a happy user of rsync -e ssh and use it to synchronize data between my machine and a remote host using
rsync -avz -e ssh me@hostA:~/folder ~/folder
And this did what I needed until now.
I am ...
13
votes
1answer
6k views
Delete extraneous files from dest dir via rsync?
Say I have
SRC
001.jpg
002.jpg
001.txt
a.zip
DEST
hello.jpg
rsync -d --delete SRC:{*.jpg,*.txt} DEST
It doesn't remove hello.jpg from DEST, any idea how to archive this?
5
votes
3answers
293 views
Copying large tree from one machine to another, maintaining ownership
I am trying to copy a large folder structure between machines. I want to maintain the ownership/rights during the copy as it is not reasonable to 'fix' the privs afterwards.
Therefore, I am using the ...
6
votes
3answers
228 views
Why does rsync fail to copy files from /sys in Linux?
I have a bash script which uses rsync to backup files in Archlinux. I noticed that rsync failed to copy a file from /sys, while cp worked just fine:
# rsync /sys/class/net/enp3s1/address /tmp
...
5
votes
3answers
5k views
Syncing directories in both directions with rsync
I happen to know about rsyn, and I use rsync to sync between my mac and a linux server as follows.
rsync -r -t -v MAC LINUX
rsync -r -t -v LINUX MAC
I expected to run the first command to sync, but ...
4
votes
3answers
633 views
Performing accurate snapshot and incremental backups to a remote server
I have a few Ubuntu (and potentially RHEL) servers I'd like to back up to a central backup server (via rsh/SSH). I'd like to do both snapshot and incremental backups. The goal is that if one of the ...
3
votes
1answer
902 views
Incremental system backup and restore w/ rsync or rdiff-backup issues
I've been reading about using rsync and rdiff-backup to make incremental backups of my entire Linux system. I am planning to practise that by setting up a Linux system, making some changes to it, ...
1
vote
1answer
325 views
rsync command to backup home tree to another disk
I want to make sure I am using the correct rsync command on Linux. I do not want to run an rsync and end up losing data as I am new to Linux and I have no backup now.
On Linux Mint, I want to backup ...
6
votes
2answers
461 views
sync files recursively between two folders where files are less than 24 hours old
I want to find all the files under a directory which are within 24 hours then rsync those files with another server.
There are some old files that I do not want to transfer, however if those old ...
4
votes
2answers
356 views
Sync files from a mac to a flash drive - automatically?
I have a flash drive, let's name it FLASH.
I want, when on my mac, when FLASH is plugged (and automatically mounted), execute a specific script and make ~/Documents to be automatically copied to ...
2
votes
1answer
271 views
rsync an mpd playlist
An mpd playlist looks like this:
syncrel.m3u
Bob Dylan - The Times They Are A-Changin' [V0]/04. One Too Many Mornings.mp3
Bob Dylan - The Times They Are A-Changin' [V0]/01. The Times They Are ...
2
votes
1answer
5k views
“rsync: failed to set permissions on …” error with rsync -a or -p option
When I use the -a option as is asked and answered in Preserve the permissions with rsync, I got a lot of "rsync: failed to set permissions on" errors.
rsync: failed to set permissions on ...
1
vote
1answer
146 views
How to let rsync additionally store an differential changelog in another directory?
I'm using rsync --link-dir to obtain daily snapshots with little space usage due to the hardlinking. It would however be nice to also have a directory that, while mirroring the original structure, ...
1
vote
1answer
1k views
Preserve the permissions with rsync
Let's say I have a file a.txt in LINUX with permission of 0664.
When I use rsync to copy the file to my Mac with rsync -r -t -v LINUX MAC, the file's permission becomes 0644.
How can I keep the ...
0
votes
2answers
83 views
How to detect particular system call called or not in a whole workflow?
EDIT No. 1
My task is mirroring , i.e., copying updated data from master server to all mirrors, by using rsync and rsh. But during rsync and rsh, I found some delay. My thinking is , the reason for ...
0
votes
1answer
407 views
how to tell rsync to preserve time stamp on files when source tree has a mounted point
Related to this question
Short description of the problem
When source tree has a mounted point inside it, then time stamps on files inside that mounted point when copied to target tree are not ...