What is the simplest way to unidirectional incremental syncing of a folder present on a Linux system.
+1 for using the command line. +2 for not using rsync (Seems to have some problems on my system.)
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
csync is a file synchronizer especially designed for you, the normal user.
csync is a library and ships commandline client by default. It is server-less and allows synchronisation through either
csync /home/csync smb://csync:email@example.com/Users/csync csync /home/csync sftp://firstname.lastname@example.org:2222/home/csync
This is how I would do a unidirectional sync with bare tools.
At the onset, tar the entire set of files and copy them to the destination point.
Also, setup a marker in the base directory.
Now, we want to keep sync'ing from Source to Destination.
At the next time slot for syncing forward (from Source to Destination),
# The backup script cd /Source/base/directory tar cfj -N ./last-sync-time.txt backup.tar.bz2 . scp backup.tar.bz2 user@backup-server:/Backup/Directory/ touch /Source/base/directory/last-sync-time.txt rm -f backup.tar.bz2
-N ./filenametells tar to archive only files modified or created after
scpwith public key authentication
backup-serverwhenever this script is issued.