Rsync and replication server

Status
Not open for further replies.

Daniel.p

Cadet
Joined
Jan 25, 2014
Messages
3
Hi Guys ,

i currently am running two freenas servers with the main server replicating its self to the second via rsync
using the Rsync task.

Now i have only just done this in the last week or so but have a few questions .

now the backup schedule is once a week on a sunday night .

my question is this .

i understand the first time the backup runs it will copy everything to the backup server .

as i add files to the main server will the server copy all the files again or only the new files that have been added to the main server .

example

File 1 ,2 ,3 ,4 copied on sunday night to the backup server .

monday morning i add file 5,6,7,8 to the main server .

sunday comes around again but will it copy file 1,2,3,4 + the new added files 5,6,7,8

or only copy over file 5,6,7,8

i know it sounds long winded but note sure how to explain any other way .
 

adrianwi

Guru
Joined
Oct 15, 2013
Messages
1,231
It depends on the rsync command you are using. I'd have a look in the manual for snapshots and ZFS replication. In my experience, this is the easiest way to backup to a 2nd FreeNAS machine.
 

depasseg

FreeNAS Replicant
Joined
Sep 16, 2014
Messages
2,874
i currently am running two freenas servers with the main server replicating its self to the second via rsync
using the Rsync task.
I'm curious why you wouldn't use ZFS replication. I know that in your example, it will only copy the blocks that are different in whatever snapshots have been taken between the 2 replication tasks.
 

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778
as i add files to the main server will the server copy all the files again or only the new files that have been added to the main server
rsync will only copy new files and changed blocks of existing files, unless you deliberately tell it to copy everything.

rsync is an excellent tool for many tasks, but not necessarily the best tool for replicating one FreeNAS box to another, primarily because it doesn't preserve the full filesystem structure. This might not seem important now (I'm guessing your current configuration is very simple) but over time you'll probably end up with a more involved setup and snapshot replication will be more appropriate.
 
Status
Not open for further replies.
Top