I have set this up in Xenial/Bionic/Eoan
The following syncs nicely a dir created as root to need the sudo to read it:

$ rsync -AEaogt --rsync-path="sudo rsync" -e "ssh -o
StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null" /tmp/foo
[email protected]:/tmp

This works among all pairs and cross releases.

Now lets brainstorm what might happen in your case ...

I have:
1. setup rsync to be sudo enabled without PW in /etc/sudoers
  %sudo ALL= NOPASSWD:/usr/bin/rsync
2. then I exchanged ssh keys between all nodes

That got it working, no more needed.

Did you use the same sudoers hint to make it PW-less?

I have read through your log twice but can't find anything obvious.
You could try to set up another user special to this use case.
And let that user have no .bashrc nor anything else (maybe the login with rsync 
triggers a different path and there you have output). At least that would be an 
easy try.

Most things you find on the net about this is about clearing the non
interactive login, but I think you have done that. What might be worth
to take a look is dropping strict host keycheck option and really make
sure all keys are accepted - maybe something with that is going on in
the background?

** Changed in: rsync (Ubuntu)
       Status: New => Incomplete

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1831101

Title:
  rsync with remote sudo fails over ssh/pki with protocol mismatch error

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/rsync/+bug/1831101/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to