Rsync: error starting client-server protocol (code 5)

While setting up a new server, I encountered the, sometime vague, “error starting client-server protocol (code 5)” when trying to rsync the files from the box to be replaced.

On the source server, the in /var/log/messages, I found:

Apr 12 08:59:09 REDACTED rsyncd[19871]: auth failed on module etc from REDACTED (REDACTED): invalid challenge response

I was confident that the credentials were good, as I was using a copy of a script that worked.

I started poking around on the source server and found that the secrets file had permissions that allowed all users to read it. I’ve seen this type of issue before, I thought. I set the user and group for the secrets file to root.root. Then set it so only the user could write and the group could only read: chmod 0640 secrets. Now, I have this:

-rw-r—– 1 root root 14 Dec 20 2017 pwd
-rw-r—– 1 root root 21 Apr 12 08:48 secrets

And blessings be, it worked! Yay!

Happy Slacking!
Stu…

1 thought on “Rsync: error starting client-server protocol (code 5)”

  1. hello

    I have been having the same error when running rsync as a service within freenas.

    I have 4 identical data sets with same owner same user group same acl, yet i can backup 3 of these datasets Movies, documents and music with no issue my tv shows datasets will not back up for the live of me. The only difference is that tv shows is 2 words as opposed to the others with single word.
    I am very inexperienced in and i do not fully understand what you are saying here above.

    to make matters worse when i go in freenas shell and try to enter a command i get a zsh error

    Reply

Leave a Comment