Sebastian Arcus
2012-Oct-31 11:17 UTC
What happens after --max-delete is reached? Are updates processed?
Reading the manual page: "This tells rsync not to delete more than NUM files or directories." Also, according to docs, rsync exits with code 25 if max-delete has been reached. Now, rsync starts with the deletes by default, and then it does updates. My question is, if --max-delete has been reached, does rsync still proceed with the updates (not the deletes), or just exists immediately with code 25 without doing any updates? The man page doesn't specify either way, and looking at online posts, it would seem to suggest it exits as soon as max-delete has been reached. Thanks, Sebastian
Voelker, Bernhard
2012-Oct-31 11:38 UTC
What happens after --max-delete is reached? Are updates processed?
Sebastian Arcus wrote (Wednesday, October 31, 2012 12:18 PM):> Reading the manual page: "This tells rsync not to delete more than NUM > files or directories." Also, according to docs, rsync exits with code 25 > if max-delete has been reached. Now, rsync starts with the deletes by > default, and then it does updates. > > My question is, if --max-delete has been reached, does rsync still > proceed with the updates (not the deletes), or just exists immediately > with code 25 without doing any updates? The man page doesn't specify > either way, and looking at online posts, it would seem to suggest it > exits as soon as max-delete has been reached.>From trying, I'd say it continues with updating(for whatever case that would make sense ...): $ mkdir a b $ touch a/a b/b $ rsync -aix --delete --max-delete=0 a/. b/. >f+++++++++ a Deletions stopped due to --max-delete limit (1 skipped) rsync error: the --max-delete limit stopped deletions (code 25) at main.c(1052) [sender=3.0.9] $ echo $? 25 $ ls b/* b/a b/b Have a nice day, Berny
Possibly Parallel Threads
- [ reached getOption("max.print") -- omitted 8178 rows ]]
- [ reached getOption("max.print") -- omitted 138 rows]
- delete files
- [Bug 2408] New: when more than --max-delete files are about to be deleted no error is returned
- [Bug 2408] when more than --max-delete files are about to be deleted no error is returned