<div dir="ltr">Hello Kevin,<div><br></div><div>Thank you for your answer. Yes, sorry, I forgot to mention that test. I did it. The result is:</div><div><br></div><div><div>backup-user@backup:~$ /usr/bin/ssh -q -x -l backup-user 192.168.10.20 true > testfile</div><div>backup-user@backup:~$ ll testfile </div><div>-rw-r--r-- 1 backup-user backup-user 0 feb 16 02:26 testfile</div></div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><pre>--</pre><pre>Francisco López<br>flopez @ <a href="http://hispasec.com" target="_blank">hispasec.com</a><br>Hispasec Sistemas<br>+34 952 020 494<br>Málaga (Spain) 
</pre><pre>--</pre></div></div></div>
<br><div class="gmail_quote">2016-02-16 2:24 GMT+01:00 Kevin Korb <span dir="ltr"><<a href="mailto:kmk@sanitarium.net" target="_blank">kmk@sanitarium.net</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">-----BEGIN PGP SIGNED MESSAGE-----<br>
Hash: SHA1<br>
<br>
Did you do the clean shell test?<br>
/usr/bin/ssh -q -x -l backup-user 192.168.10.20 true > testfile<br>
After running that, testfile should be 0 bytes.<br>
<div><div class="h5"><br>
On 02/15/2016 08:13 PM, Francisco López wrote:<br>
> Hello,<br>
><br>
> I just installed BackupPC in a Debian box to use it as backup<br>
> server. As you know, this software makes use, among others, of<br>
> rsync. When using the rsync option, it fails.<br>
><br>
> Server: Debian Jessie. BackupPC 3.3.1 built from source, executed<br>
> by user "backup-user". Rsync 3.1.2 built from source with the<br>
> default options.<br>
><br>
> Client Debian Jessie. Rsync 3.1.2 built from source with the<br>
> default options.<br>
><br>
> After the fail, the rsync command used can be found in BackupPC's<br>
> logs. Trying the command in a shell, logged as the BackupPC user, I<br>
> run into this "protocol version mismatch -- is your shell clean?"<br>
> error. The command is:<br>
><br>
> /usr/bin/ssh -q -x -l backup-user 192.168.10.20<br>
> /usr/local/bin/rsync --server --sender --numeric-ids --perms<br>
> --owner --group -D --links --hard-links --times --block-size=2048<br>
> --recursive --ignore-times . /home/backup-user/test<br>
><br>
> Adding some verbose to the rsync command sent to the client, it<br>
> says:<br>
><br>
> FILE_STRUCT_LEN=24, EXTRA_LEN=4<br>
><br>
> (Server) Protocol versions: remote=168430090, negotiated=31<br>
> ########################### Notice the remote protocol version<br>
> protocol version mismatch -- is your shell clean? (see the rsync<br>
> man page for an explanation) [sender] _exit_cleanup(code=2,<br>
> file=compat.c, line=178): entered rsync error: protocol<br>
> incompatibility (code 2) at compat.c(178) [sender=3.1.2] [sender]<br>
> _exit_cleanup(code=2, file=compat.c, line=178): about to call<br>
> exit(2)<br>
><br>
> In the client, using the debug script I found in this site:<br>
><br>
> /usr/bin/ssh -q -x -l backup-user 192.168.206.103<br>
> /home/backup-user/rsync-debug --server --sender --numeric-ids<br>
> --perms --owner --group -D --links --hard-links --times<br>
> --block-size=2048 --recursive --ignore-times .<br>
> /home/backup-user/test<br>
><br>
> rsync-2991.out content:<br>
><br>
> 2997  00:58:30 brk(0)                   = 0xefb000 2997  00:58:30<br>
> access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or<br>
> directory) 2997  00:58:30 mmap(NULL, 8192, PROT_READ|PROT_WRITE,<br>
> MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fefc7341000 2997  00:58:30<br>
> access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or<br>
> directory) 2997  00:58:30 open("/etc/ld.so.cache",<br>
> O_RDONLY|O_CLOEXEC) = 3 2997  00:58:30 fstat(3,<br>
> {st_mode=S_IFREG|0644, st_size=33837, ...}) = 0 2997  00:58:30<br>
> mmap(NULL, 33837, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fefc7338000<br>
> 2997  00:58:30 close(3)                 = 0 2997  00:58:30<br>
> access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or<br>
> directory) 2997  00:58:30 open("/lib/x86_64-linux-gnu/libc.so.6",<br>
> O_RDONLY|O_CLOEXEC) = 3 2997  00:58:30 read(3,<br>
> "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0P\34\2\0\0\0\0\0@\0\0\0<br>
\0\0\0\0\300T\32\0\0\0\0\0\0\0\0\0@\0008\0\n\0@\0D\0C\0\6\0\0\0\5\0\0\0@<br>
\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0000\2\0\0\0\0\0\0000\2\0\0\0<br>
\0\0\0\10\0\0\0\0\0\0\0\3\0\0\0\4\0\0\0000\303\26\0\0\0\0\0000\303\26\0\<br>
0\0\0\0000\303\26\0\0\0\0\0\34\0\0\0\0\0\0\0\34\0\0\0\0\0\0\0\20\0\0\0\0<br>
\0\0\0\1\0\0\0\5\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\3<br>
64\352\31\0\0\0\0\0\364\352\31\0\0\0\0\0\0\0<br>
><br>
><br>
\0\0\0\0\0\1\0\0\0\6\0\0\0@\367\31\0\0\0\0\0@\3679\0\0\0\0\0@\3679\0\0\0<br>
\0\0\370O\0\0\0\0\0\0\340\222\0\0\0\0\0\0\0\0<br>
> \0\0\0\0\0\2\0\0\0\6\0\0\0\240 \32\0\0\0\0\0\240 :\0\0\0\0\0\240<br>
> :\0\0\0\0\0\340\1\0\0\0\0\0\0\340\1\0\0\0\0\0\0\10\0\0\0\0\0\0\0\4\0\0<br>
\0\4\0\0\0p\2\0\0\0\0\0\0p\2\0\0\0\0\0\0p\2\0\0\0\0\0\0D\0\0\0\0\0\0\0D\<br>
0\0\0\0\0\0\0\4\0\0\0\0\0\0\0\7\0\0\0\4\0\0\0@\367\31\0\0\0\0\0@\3679\0\<br>
0\0\0\0@\3679\0\0\0\0\0\20\0\0\0\0\0\0\0\200\0\0\0\0\0\0\0\10\0\0\0\0\0\<br>
0\0P\345td\4\0\0\0L\303\26\0\0\0\0\0L\303\26\0\0\0\0\0L\303\26\0\0\0\0\0<br>
$j\0\0\0\0\0\0$j\0\0\0\0\0\0\4\0\0\0\0\0\0\0Q\345td\6\0\0\0\0\0\0\0\0\0\<br>
0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\20\0<br>
\0\0\0\0\0\0R\345td\4\0\0\0@\367\31\0\0\0\0\0@\3679\0\0\0\0\0@\3679\0\0\<br>
0\0\0\3008\0\0\0\0\0\0\3008\0\0\0\0\0\0\1\0\0\0\0\0\0\0\4\0\0\0\24\0\0\0<br>
\3\0\0\0GNU\0\371?y\343\344|\332K|C=\2\323!\316@\34J\205\1\4\0\0\0\20\0\<br>
0\0\1\0\0\0GNU\0\0\0\0\0\2\0\0\0\6\0\0\0<br>
><br>
><br>
\0\0\0\0\0\0\0\363\3\0\0\n\0\0\0\0\1\0\0\16\0\0\0\0000\20D\240<br>
> \2\1\210\3\346\220\305E\214\0\300\0\10\0\5\200\0`\300\200\0\r\212\f\0\<br>
4\20\0\210D2\10.@\210P4,<br>
><br>
><br>
\16\"H&\204\300\214\4\10\0\2\2\16\241\254\32\4f\300\0\3002\0\300\0P\1<br>
> \201\10\204\v  ($\0\4 P\0\20X\200\312DB(\0\6\200\20\30B\0<br>
> @\200\0\tP\0Q\212@\20\0\0\0\0\10\0\0\21\20", 832) = 832 2997<br>
> 00:58:30 fstat(3, {st_mode=S_IFREG|0755, st_size=1729984, ...}) =<br>
> 0 2997  00:58:30 mmap(NULL, 3836448, PROT_READ|PROT_EXEC,<br>
> MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fefc6d7a000 2997  00:58:30<br>
> mprotect(0x7fefc6f19000, 2097152, PROT_NONE) = 0 2997  00:58:30<br>
> mmap(0x7fefc7119000, 24576, PROT_READ|PROT_WRITE,<br>
> MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x19f000) = 0x7fefc7119000<br>
> 2997  00:58:30 mmap(0x7fefc711f000, 14880, PROT_READ|PROT_WRITE,<br>
> MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7fefc711f000 2997<br>
> 00:58:30 close(3)                 = 0 2997  00:58:30 mmap(NULL,<br>
> 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =<br>
> 0x7fefc7337000 2997  00:58:30 mmap(NULL, 4096,<br>
> PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =<br>
> 0x7fefc7336000 2997  00:58:30 mmap(NULL, 4096,<br>
> PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =<br>
> 0x7fefc7335000 2997  00:58:30 arch_prctl(ARCH_SET_FS,<br>
> 0x7fefc7336700) = 0 2997  00:58:30 mprotect(0x7fefc7119000, 16384,<br>
> PROT_READ) = 0 2997  00:58:30 mprotect(0x7fefc7343000, 4096,<br>
> PROT_READ) = 0 2997  00:58:30 munmap(0x7fefc7338000, 33837) = 0<br>
> 2997  00:58:30 rt_sigaction(SIGUSR1, {0x41c690, [],<br>
> SA_RESTORER|SA_NOCLDSTOP, 0x7fefc6daf180}, NULL, 8) = 0 2997<br>
> 00:58:30 rt_sigaction(SIGUSR2, {0x41d220, [],<br>
> SA_RESTORER|SA_NOCLDSTOP, 0x7fefc6daf180}, NULL, 8) = 0 2997<br>
> 00:58:30 rt_sigaction(SIGCHLD, {0x41c630, [],<br>
> SA_RESTORER|SA_NOCLDSTOP, 0x7fefc6daf180}, NULL, 8) = 0 2997<br>
> 00:58:30 geteuid()                = 1001 2997  00:58:30 getegid()<br>
> = 1001 2997  00:58:30 umask(0)                 = 022 2997  00:58:30<br>
> umask(022)               = 0 2997  00:58:30 brk(0)<br>
> = 0xefb000 2997  00:58:30 brk(0xf1c000)            = 0xf1c000 2997<br>
> 00:58:30 open("/usr/lib/locale/locale-archive", O_RDONLY|O_CLOEXEC)<br>
> = 3 2997  00:58:30 fstat(3, {st_mode=S_IFREG|0644, st_size=1607632,<br>
> ...}) = 0 2997  00:58:30 mmap(NULL, 1607632, PROT_READ,<br>
> MAP_PRIVATE, 3, 0) = 0x7fefc71ac000 2997  00:58:30 close(3)<br>
> = 0 2997  00:58:30 open("/etc/popt", O_RDONLY) = -1 ENOENT (No such<br>
> file or directory) 2997  00:58:30 open("/home/backup-user/.popt",<br>
> O_RDONLY) = -1 ENOENT (No such file or directory) 2997  00:58:30<br>
> rt_sigaction(SIGINT, {0x40cca0, [], SA_RESTORER|SA_NOCLDSTOP,<br>
> 0x7fefc6daf180}, NULL, 8) = 0 2997  00:58:30 rt_sigaction(SIGHUP,<br>
> {0x40cca0, [], SA_RESTORER|SA_NOCLDSTOP, 0x7fefc6daf180}, NULL, 8)<br>
> = 0 2997  00:58:30 rt_sigaction(SIGTERM, {0x40cca0, [],<br>
> SA_RESTORER|SA_NOCLDSTOP, 0x7fefc6daf180}, NULL, 8) = 0 2997<br>
> 00:58:30 rt_sigprocmask(SIG_UNBLOCK, [HUP INT USR1 USR2 TERM CHLD],<br>
> NULL, 8) = 0 2997  00:58:30 rt_sigaction(SIGPIPE, {SIG_IGN, [],<br>
> SA_RESTORER|SA_NOCLDSTOP, 0x7fefc6daf180}, NULL, 8) = 0 2997<br>
> 00:58:30 rt_sigaction(SIGXFSZ, {SIG_IGN, [],<br>
> SA_RESTORER|SA_NOCLDSTOP, 0x7fefc6daf180}, NULL, 8) = 0 2997<br>
> 00:58:30 getcwd("/home/backup-user", 4095) = 13 2997  00:58:30<br>
> fcntl(0, F_GETFL)        = 0 (flags O_RDONLY) 2997  00:58:30<br>
> fcntl(0, F_SETFL, O_RDONLY|O_NONBLOCK) = 0 2997  00:58:30 fcntl(1,<br>
> F_GETFL)        = 0x1 (flags O_WRONLY) 2997  00:58:30 fcntl(1,<br>
> F_SETFL, O_WRONLY|O_NONBLOCK) = 0 2997  00:58:30 fcntl(0, F_GETFL)<br>
> = 0x800 (flags O_RDONLY|O_NONBLOCK) 2997  00:58:30 fcntl(1,<br>
> F_GETFL)        = 0x801 (flags O_WRONLY|O_NONBLOCK) 2997  00:58:30<br>
> write(1, "\37\0\0\0", 4) = 4 ####################################<br>
> Here is where the script stops #############<br>
> ############################# I have to hit return several times in<br>
> the server ######## 2997  00:58:30 select(1, [0], NULL, [0], {60,<br>
> 0}) = 1 (in [0], left {55, 558348}) 2997  00:58:34 read(0, "\n", 4)<br>
> = 1 2997  00:58:34 select(1, [0], NULL, [0], {60, 0}) = 1 (in [0],<br>
> left {59, 793510}) 2997  00:58:35 read(0, "\n", 3)         = 1 2997<br>
> 00:58:35 select(1, [0], NULL, [0], {60, 0}) = 1 (in [0], left {59,<br>
> 975726}) 2997  00:58:35 read(0, "\n", 2)         = 1 2997  00:58:35<br>
> select(1, [0], NULL, [0], {60, 0}) = 1 (in [0], left {59, 968630})<br>
> 2997  00:58:35 read(0, "\n", 1)         = 1 2997  00:58:35 write(2,<br>
> "protocol version mismatch -- is your shell clean?", 49) = 49 2997<br>
> 00:58:35 write(2, "\n", 1)        = 1 2997  00:58:35 write(2, "(see<br>
> the rsync man page for an explanation)", 43) = 43 2997  00:58:35<br>
> write(2, "\n", 1)        = 1 2997  00:58:35 rt_sigaction(SIGUSR1,<br>
> {SIG_IGN, [], SA_RESTORER, 0x7fefc6daf180}, NULL, 8) = 0 2997<br>
> 00:58:35 rt_sigaction(SIGUSR2, {SIG_IGN, [], SA_RESTORER,<br>
> 0x7fefc6daf180}, NULL, 8) = 0 2997  00:58:35 write(2, "rsync error:<br>
> protocol incompatibility (code 2) at compat.c(178) [sender=3.1.2]",<br>
> 78) = 78 2997  00:58:35 write(2, "\n", 1)        = 1 2997  00:58:35<br>
> nanosleep({0, 100000000}, NULL) = 0 2997  00:58:35 exit_group(2)<br>
> = ? 2997  00:58:35     exited with 2<br>
><br>
> After some hours of research, I can't figure out what is wrong. I<br>
> removed and checked everything that could write any text (ssh<br>
> welcome message, .bashrc echos, passphrase and even the system<br>
> prompt) and rsync is still unable to gather the files. ssh<br>
> connection is made passwordless.<br>
><br>
> Looks like the 168430090 in the remote protocol is the decimal<br>
> representation for 0xA0A0A0A, but no clue of what is writing it. I<br>
> searched for similar errors in the list, but all I found are due<br>
> to things I already checked.<br>
><br>
> The lines: 2997  00:58:30 open("/etc/popt", O_RDONLY) = -1 ENOENT<br>
> (No such file or directory) 2997  00:58:30<br>
> open("/home/backup-user/.popt", O_RDONLY) = -1 ENOENT (No such file<br>
> or directory)<br>
><br>
> Looks suspicious to me, but also checked the libraries involved.<br>
><br>
> Options --server and --sender are added by BackupPC, but are not<br>
> supposed to be needed in a regular use, as the rsync documentation<br>
> states.<br>
><br>
> Hope this information is clear enough. Thanks for your time.<br>
><br>
><br>
<br>
</div></div>- --<br>
~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,<br>
        Kevin Korb                      Phone:    <a href="tel:%28407%29%20252-6853" value="+14072526853">(407) 252-6853</a><br>
        Systems Administrator           Internet:<br>
        FutureQuest, Inc.               Kevin@FutureQuest.net  (work)<br>
        Orlando, Florida                <a href="mailto:kmk@sanitarium.net">kmk@sanitarium.net</a> (personal)<br>
        Web page:                       <a href="http://www.sanitarium.net/" rel="noreferrer" target="_blank">http://www.sanitarium.net/</a><br>
        PGP public key available on web site.<br>
~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,<br>
-----BEGIN PGP SIGNATURE-----<br>
Version: GnuPG v2<br>
<br>
iEYEARECAAYFAlbCelYACgkQVKC1jlbQAQdKTgCgy3hO4GMZ4/OiC9bDhICSYmDu<br>
AfAAn32LO3+qj3/p6l8Tzw8G77awYV8q<br>
=hjjV<br>
-----END PGP SIGNATURE-----<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Please use reply-all for most replies to avoid omitting the mailing list.<br>
To unsubscribe or change options: <a href="https://lists.samba.org/mailman/listinfo/rsync" rel="noreferrer" target="_blank">https://lists.samba.org/mailman/listinfo/rsync</a><br>
Before posting, read: <a href="http://www.catb.org/~esr/faqs/smart-questions.html" rel="noreferrer" target="_blank">http://www.catb.org/~esr/faqs/smart-questions.html</a><br>
</font></span></blockquote></div><br></div>