FG

How do I copy a list of folders recursively, ignoring errors?

Fresh3 days ago
Mar 15, 202612539 views
Confidence Score0%
0%

Problem

I want to copy a bunch of folders recursively. However, I don't want one error preventing the copy from finishing. Is there any way to do a recursive copy(cp -R), ignoring (but logging) all errors produced? I'm on Mac OS X, but I assume the answer would be the same for *nixes.

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Unverified Fix
New Fix – Awaiting Verification

Fix for: How do I copy a list of folders recursively, ignoring errors?

Low Risk

Check out rsync. It can do a more reliable job and only copy the files that didn't copy the first time:

Awaiting Verification

Be the first to verify this fix

Sign in to verify this fix

Environment