The recursive switch
cjraven at gmail.com
Thu Mar 1 14:34:21 MST 2012
On Mar 1, 2012, at 21:52, Kevin Korb <kmk at sanitarium.net> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> Is it actually not doing anything? It should only list files that it
> is actually doing something with unless you use more than one -v. Try
> adding --itemize-changes to find out (-v is fairly useless without it
Definitively, it's not doing anything, that's for sure. No -vv for sure. I ran it with the -i switch, as a test, and yes, this did make the output a bit more terse, and the cycle measurably shorter. Sorry, I ought to have mentioned that, but was shooting for brevity...or what I call brevity anyway :) :)
> Also, don't use -z unless you are on a slow network or know that your
> data is very compressible as otherwise it only wastes CPU.
Oh that's an excellent point. The data isn't compressable, but at a second point in a 3 location backup topology, the uplink is slow [NAS1 -> NAS2 (GB LAN) -> Datacenter disk array (DSL 1.8 MB/sec)] so arguably the -z might or might not be useful at the second rsync. Principally however, I should emphasize that the issue I had problems with was over the GB LAN, the final transfer I fully expect to be slow :) :) :)
> Using -r and -a at the same time is just extra typing it will not
> cause any problems.
That really IS a relief to know, thanks! this was helpful.
> On 03/01/12 15:49, Colin Raven wrote:
>> Thanks to all for jumping in on this one. I've used rsync in a kind
>> of offhand manner for years, only now was it necessary to "get
>> serious" with it....
>> So then, using -a **includes** -r? Goodness me, I was using -ra so
>> who knows what gnarliness I was actually causing!!
>> If I can briefly say what is going on, a 9.4GB dataset changes by
>> about +50 MB per day, and is rsync'd once a day.
>> If I deliberately run rsync again right after it finished a run
>> with the combo "-rahvz" it ambles through the tree, obligingly
>> lists everything, then - concluding there's nothing to be done,
>> emits a human readable summary and exits. Unfortunately this takes
>> a rather long time, and accomplishes (of course) nothing, since
>> there's nothing to sync, but while essentially doing nothing,
>> nevertheless chews up some significant resources.
>> What is a more intelligent approach?
>> On Mar 1, 2012, at 20:40, Kevin Korb <kmk at sanitarium.net> wrote:
>> Yes, -a includes -r and a bunch of other things.
>> --no-i-r disables the incremental recursion and forces rsync to
>> hold the entire tree in memory in addition to fully scanning the
>> tree on both ends before copying anything.
>> On 03/01/12 14:39, Elliot Wilen wrote:
>>>>> On Mar 1, 2012, at 11:34 AM, Kevin Korb wrote:
>>>>>> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
>>>>>> Without -r rsync will ignore all directories even if the
>>>>>> path you specified is a directory. That is what recursive
>>>>>> If you are having memory usage issues make sure you are
>>>>>> running rsync version 3 on both ends and check that you
>>>>>> aren't using any of the options that conflict with
>>>>>> incremental recursion (like --delete-before).
>>>>> Which contradicts what I wrote about using --no-i-r. I defer
>>>>> to Kevin.
>>>>> But again, note that -a includes -r.
>>>>> Elliot Wilen Network Administrator/Postmaster Communications
>>>>> and Information Systems MPR Associates, Inc. 2150 Shattuck
>>>>> Ave., Suite 800 Berkeley, CA 94704 Phone: (510) 849-4942 Fax:
>>>>> (510) 849-0794
>>> -- Please use reply-all for most replies to avoid omitting the
>>> mailing list. To unsubscribe or change options:
>>> https://lists.samba.org/mailman/listinfo/rsync Before posting,
>>> read: http://www.catb.org/~esr/faqs/smart-questions.html
> - --
> Kevin Korb Phone: (407) 252-6853
> Systems Administrator Internet:
> FutureQuest, Inc. Kevin at FutureQuest.net (work)
> Orlando, Florida kmk at sanitarium.net (personal)
> Web page: http://www.sanitarium.net/
> PGP public key available on web site.
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2.0.17 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> -----END PGP SIGNATURE-----
More information about the rsync