FG

Resume rsync over SSH after broken connection?

Fresh3 days ago
Mar 15, 202659084 views
Confidence Score1%
1%

Problem

I have to transfer large amounts of data (>80 GB) over ssh using rsync. Everything is working fine, but the DSL connection where the backup data is sent from will drop once every 24h for up to 3 minutes (switching providers is not an option). How do I: Automatically restart the transfer when the connection is back up? Make sure there are not by accident two rsync commands running at the same time?

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Unverified Fix
New Fix – Awaiting Verification

Fix for: Resume rsync over SSH after broken connection?

Low Risk

The following should be helpful: When the connection dies, rsync will quit with a non-zero exit code. This script simply keeps re-running rsync, letting it continue until the synchronisation completes normally.

Awaiting Verification

Be the first to verify this fix

Sign in to verify this fix

Environment