1

I have implemented a multi-server backup system, which is working quite effectively.

I have a backup server with a large disk-array, and every night it runs rsnapshot to backup relevant data on all servers on the LAN (linux/windows). Connection to server is via regular ssh connections.

This is the relevant (simplified) part of my rsnapshot.conf:

...
backup   user@server-one:/etc/            backup-server-one/
backup   user@server-one:/opt/            backup-server-one/
backup   user@server-two:/etc/            backup-server-two/
backup   user@server-two:/var/            backup-server-two/
backup   user@server-three:/etc/          backup-server-three/
backup   user@server-three:/home/user/    backup-server-three/
...

So far so good. The problem is that, when for some reason one backup fails (typically because that server is down...), the whole rsnapshot process dies, and all following snapshots are not executed...

The question is: is it possible to persuade rsnapshot to proceed to next 'backup', even in case of an error?

MarcoS
  • 111
  • 5

2 Answers2

0

I did implement myself a solution... In sub handle_rsync_error I did change

if (0 == $retval) { bail('retval == 0 in handle_rsync_error() ('.$$bp_ref{'src'}.')'); }

with

if (0 == $retval) {
    print_err ("$config_vars{'cmd_rsync'} error 0 on $$bp_ref{'src'} (check host is up and accepting ssh connections...)", 2);
    syslog_err("$config_vars{'cmd_rsync'} error 0 on $$bp_ref{'src'} (check host is up and accepting ssh connections...)");
  }

Testing right now, but quite confident... :-)

MarcoS
  • 111
  • 5
0

@MarcoS: nice ;-)

I wrote myself an rsnapshot-wrapper and have one configuration file for one host, so even if one rsnapshot run fails, it will continue with the next one.

ckujau
  • 642
  • 4
  • 13
  • nice ;-)) I didn't see your code... I will stay with mine, it's working for me, now... Some days ago I did post an issue on rsnapshot's github, but it looks like it's no more actively supported... (no feedack, yet) :-( – MarcoS Jan 22 '14 at 08:16