Mention strace alternatives, such as truss and tusc.
[rsync-web.git] / issues.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
2 <HTML>
3 <HEAD>
4 <TITLE>rsync current issues</TITLE>
5 </HEAD>
6 <!--#include virtual="header.html" -->
7
8 <H2 align="center">Current issues</H2>
9
10 <ol>
11
12 <li><p><b>Q:</b>
13
14 Transfers die with something like
15
16 <pre>rsync: error writing 4 unbuffered bytes - exiting: Broken pipe
17 rsync error: error in rsync protocol data stream (code 12) at io.c(463)
18 </pre>
19
20 <p>or
21
22 <pre>rsync: connection unexpectedly closed (24 bytes read so far)
23 rsync error: error in rsync protocol data stream (code 12) at io.c(342)
24 </pre>
25
26 <p><b>A:</b>
27
28 Sometimes fatal error messages from the remote machine can be lost on
29 the way to the client or the remote process may have died; you should
30 investigate on the server for something stopping the transmission.
31 Several common causes:
32
33 <ul>
34 <li>The destination disk is full.
35 <li>The remote rsync executable wasn't found.
36 <li>Your remote-shell setup isn't working right or isn't "clean"
37 (i.e. is sending spurious text to rsync).
38 </ul>
39
40 <p>If you think you've found a bug, you'll need to help track down the
41 cause of the failure (since the above errors just tell us that something
42 went wrong remotely, not what went wrong).  One way is to create a shell
43 script such as <a href="rsync-debug">this one named rsync-debug</a>.
44 You would use the script like this:
45
46 <pre>rsync -av --rsync-path=/some/path/rsync-debug HOST:SOURCE DEST
47 rsync -av --rsync-path=/some/path/rsync-debug SOURCE HOST:DEST
48 </pre>
49
50 <p>This script enables core dumps and also logs all the OS system calls
51 that lead up to the failure to a file in the /tmp dir.  You can use the
52 resulting files to help figure out why the remote rsync failed.
53
54 <p>If you are rsyncing to an rsync daemon, the above script won't have
55 an effect.  Instead, halt the current daemon and restart it under a
56 system-call tracing utility such as <i>strace</i>, <i>truss</i>, or
57 <i>tusc</i>.  For strace, you would do it like this (the -f option
58 tells strace to follow the child processes too):
59
60 <pre>strace -f rsync --daemon --no-detach 2&gt;/tmp/rsync-$$.out
61 </pre>
62
63 <p>If you are using rsync under inetd, I'd suggest temporarily disabling
64 that and using the above daemon approach to debug what is going on.
65
66 <li><p><b>Q:</b>
67
68 When connecting to an rsync daemon (using the "::" syntax) the
69 connection fails immediately with an error like this:
70
71 <pre>rsync: connection unexpectedly closed (24 bytes read so far)
72 rsync error: error in rsync protocol data stream (code 12) at io.c(342)
73 </pre>
74
75 <p><b>A:</b>
76
77 Older rsync daemons (pre 2.6.3) were unable to return errors that were
78 generated during the option-parsing phase of the transfer.  Look in the
79 logfile on the server to see if an error was reported, such as a
80 "refused" option, an option that the server rsync doesn't support (e.g.
81 perhaps links are not supported by the server), or some other failure
82 (such as trying to send data to a read-only module).
83
84 <li><p><b>Q:</b>
85
86 Using --dry-run (-n) doesn't show all changed directories.
87
88 <p><b>A:</b>
89
90 Correct.  Rsync shows most other changes, but some directory changes are
91 not currently described in --dry-run mode.  Hopefully a future version
92 will fix this.
93
94 <li><p><b>Q:</b>
95
96 Aren't there more issues than this?
97
98 <p><b>A:</b>
99
100 Yes.  You can find some of them in the <a href="/ftp/rsync/TODO">TODO file</a> or
101 <a href="https://bugzilla.samba.org/buglist.cgi?product=rsync&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=RESOLVED&bug_status=VERIFIED">search the bugzilla database</a>.
102
103 </ol>
104
105 <!--#include virtual="footer.html" -->