[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#20094: cp --dry-run

From: Bernhard Voelker
Subject: bug#20094: cp --dry-run
Date: Sun, 15 Mar 2015 23:36:33 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0

On 03/13/2015 05:58 PM, 積丹尼 Dan Jacobson wrote:
> I'm pretty much sure I can successfully cp/mv entire
> complicated tree A onto entire complicated tree B, but it would be great
> to know before I get started if deep inside B there is something that
> will cause some tiny part of the whole operation to fail.

I don't think a dry-run could ever predict a failure in a reliable way.
As an abstract example let's assume that such a clever copy program would
calculate the needed space in the destination upfront, and would be able
to issue an error like "the command would fail because of low disk space".
But in the case the space is sufficient (at the time of calculation), it
could never predict external influences, e.g. another program filling the
disk at the same time.  The same applies to permission issues, etc.: even
if the determination of an issue is accurate, it would still be racy in
every case.

Have a nice day,

reply via email to

[Prev in Thread] Current Thread [Next in Thread]