How to make an incremental backup?

I’ve been looking for a simple backup solution but only found the following text within Endless Help:

Blockquote
To make sure you don’t lose your files, it is a good idea to perform regular back ups. To back up your files, copy your files to a safe location, such as an external hard drive, another computer on the network, or a USB drive. Your personal files and settings are usually in your Home folder, so you can copy them from there.

And the same recommendation in https://community.endlessos.com/t/getting-closer-to-full-time/6171.

Only with lots of GBs of data (music, videos, photos) this is no option; I would rather make an incremental backup, i.e. to copy only new/modified files once a week (+ a full backup every 3 months).
Unfortunately I didn’t find any backup tool or way do this, and even via terminal/bash shell this seems quite complicated to accomplish.
In Windows 10 this was much easier, using e.g. “ROBOCOPY /maxage:20180701” (see https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/robocopy) - or maybe I’m just missing something?

Hi there!

Unfortunately, there is no real solution to this in Endless currently - and nothing on flathub that would give us a quick solution either…

However, if you’ve heard of RoboCopy in Windows, we have a tool called rsync which is a powerful command line tool for achieving similar results.

A quick code snippet might look something like this:

rsync -auv --exclude ‘.svn’ --exclude ‘*.pyc’ source destination

where:

rsync is the command
-auv are the modifiers (a = archive; u = update so skipping files that are older in the source than those in the destination; v = verbose)
exclude files or types you don’t want to backup

source is where your files are - might be /home/documents or /sysroot/home/my_folder/Documents
destination is where you want to back up to /home/backups

Once you’ve done your backup, simply move it to an external drive or a location on your network.

You could make a shell script from this and run it manually or as a cron job - that’s a whole new thing though and not part of the backup really.

Someone may be along soon with a more elegant solution but that’s what I think I’d be doing until they come along.

Good Luck!

1 Like

Hello!

There is a piece of software you may like to try - it is called FreeFileSync and is available in the software store.

It is a file / folder comparison and copy tool - might lend itself to your need to backup the new / changed files and folders in order to have an incremental-like backup.

Give that a go - nothing to lose!

Good Luck!

1 Like