You are Here:
Download Linux Lite 5.4 Final today - See Release Announcements



X Close Ad
X Close Ad
rsync - issues with backup function

Author (Read 1406 times)

0 Members and 1 Guest are viewing this topic.

rsync - issues with backup function
« on: February 14, 2018, 05:50:24 PM »
 

Sprintrdriver

  • Forum Regular
  • ***
  • 110
    Posts
  • Country: no
  • Reputation: 6
  • Linux Lite on Dell Lattude D620

  • Linux Lite: 4.2 64bit

  • CPU: Intel Core2 T5500

  • MEMORY: 3Gb

  • VIDEO CARD: Intel Mobile 945GM/GMS 943/940GML Express
Hi forum.

I've just set up an rsync command to make backup from home folder (ext4) to a mounted fat partition (Veracrypt volume), and I ran into a issue that rsync choose to make backup from most files - instead of make backup of only the files where date is different. That is it seems to make extra backup of files that seemingly/should have the same date stamp in source as in destination folder.
The second thing is that rsync does creates numerous empty folders into subfolders of backup directory (/rsync_backup/).

The question I have - what causes this behavior?

Extended info or comments that I believe may be relevant:
- I have run rsync before some times on Ubuntu, but never went ahead and asked in any forum. Seems that this happens only the first time that rsync is run towards a destination directory. Next time I run rsync - if it behave the same as before - same command would work as expected, and only those files that is truly changed will copy (and backup is made from old version).
- Before I ran rsync towards the new FAT volume, I had an old FAT volume that was filled up. So I made a new bigger volume - still fat file system because of access within windows - and copied all files from the old fat volume to the new fat volume.
- Is there known issues with rsync handling of fat file stamp?

The full rsync command:
Code: [Select]
rsync -tarv -b --backup-dir="/home/user2/c2/rsync_backup/$(date +"%Y-%m-%d_%H-%M")" ./ "/home/user2/c2"
The /home/user2/c2/ is the fat volume mounted by Veracrypt. Current directory is where I copy files from, ~/Documents$

[edit]
After searching around the web, I found that there is a time-stamp issue in fact when using rsync between ext/fat file systems. So I changed to:
Code: [Select]
rsync -trv --size-only --delete-before -b --backup-dir="/home/user2/c2/rsync_backup/$(date +"%Y-%m-%d_%H-%M")" ./ "/home/user2/c2"
That raise another issue - the backup-dir is located within the destination folder and was not a good idea. Is there any other options other than move it elsewhere - so that rsync doesn't deletes this particular folder?
Last Edit: February 14, 2018, 06:48:12 PM by Sprintrdriver
I won't let an old, but fully functional computer die just because some company tell me that they won't make no more security updates to their OS. Thanks Linux :)
 


Tags: backup rsync 
 

X Close Ad
X Close Ad

Download Linux Lite 5.4 Final today - See Release Announcements