Kenneth Seal
2008-Apr-09 11:34 UTC
rsync error: some files could not be transferred -- How to ignore
Hi Wayne, I read your thread online at http://lists.samba.org/archive/rsync/2005-June/012847.html and I am having a similar problem. In my case, rsync displays the error code "rsync error: some files could not be transferred (code 23)" and it kills my script. Do you have any advice on how would I go about writing, researching etc. a script to tell rsync to ignore such errors? I am using the bash shell in Mac OS 10.5.2. Any help would be much appreciated. Many thanks, Ken
Kyle Crawford
2008-Apr-09 14:55 UTC
rsync error: some files could not be transferred -- How to ignore
On Apr 8, 2008, at 11:27 PM, Kenneth Seal <hunzinker@gmail.com> wrote:> Hi Wayne, > > I read your thread online at http://lists.samba.org/archive/rsync/2005-June/012847.html > and I am having a similar problem. > > In my case, rsync displays the error code "rsync error: some files > could not be transferred (code 23)" and it kills my script. Do you > have any advice on how would I go about writing, researching etc. a > script to tell rsync to ignore such errors? > > I am using the bash shell in Mac OS 10.5.2. Any help would be much > appreciated. > > Many thanks, > Ken > -- > To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync > Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.htmlThe result code of a command is stored in a special variable named $? Check the value of that variable in an if statement immediately after the rsync line in your script If the value is 0 then there were no errors. If the value is 23, then you could log a warning or not. If there is any other value in $? , then you have another problem. If we could see the relevant lines of your script we might be able to provide more help. Also you control whether your script succeeds or fails based on the last line in your script. If you want it to succeed, the last line would be exit 0 Google for advanced bash scripting guide for more info. Kyle
Matt McCutchen
2008-Apr-10 17:48 UTC
rsync error: some files could not be transferred -- How to ignore
On Tue, 2008-04-08 at 21:27 -0600, Kenneth Seal wrote:> In my case, rsync displays the error code "rsync error: some files > could not be transferred (code 23)" and it kills my script. Do you > have any advice on how would I go about writing, researching etc. a > script to tell rsync to ignore such errors?If I were you, I would try to fix the code 23 instead of ignoring it! Rsync exits with code 23 when at least one non-fatal error occurs that may affect the correctness of the transfer. Perhaps the errors currently causing the code 23 are unimportant, but if you ignore code 23, you risk missing more important errors in the future (e.g., the nonexistence of a source argument). Look for the specific error messages in the output that are causing the code 23. If it isn't immediately obvious how to fix them, post them to the list and I'll take a look. Or if you don't care about copying the offending files, you can --exclude them. Matt -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part Url : http://lists.samba.org/archive/rsync/attachments/20080410/cf604899/attachment.bin
Possibly Parallel Threads
- rsync error: some files could not be transferred -- How to ignore
- Sorting Data Frame Without Loop
- DO NOT REPLY [Bug 4611] i always get "rsync error: some files could not be transferred (code 23)" even when there is nothing to transfer
- rsync error: some files could not be transferred (code 23) at main.c(1045)
- rsync reports "some files could not be transferred" (code 23) when problems occur with password-file