problem with rsync-daemon via ssh
Carlos Carvalho
carlos at fisica.ufpr.br
Mon Feb 17 19:02:55 MST 2014
Kevin Korb (kmk at sanitarium.net) wrote on 14 February 2014 12:51:
>Try running that ssh command line yourself and see what it says.
Doesn't say anything. But rsync is indeed run. I changed it to this
script:
#!/bin/bash
echo "run!"
echo "run!"
and
ural# rsync -avv -e "ssh -l root" ./orig/ machine::module/
opening connection using: ssh -l root machine rsync --server --daemon . (8 args)
rsync: server sent "run!" rather than greeting
rsync error: error starting client-server protocol (code 5) at main.c(1635) [sender=3.1.1pre1]
Using a higher debugging (with the real rsync):
ural# rsync -a --debug=all4 -e "ssh -l root" ./orig/ machine::module/
FILE_STRUCT_LEN=24, EXTRA_LEN=4
cmd=ssh -l root machine=machine user=<NULL> path=module/
cmd[0]=ssh cmd[1]=-l cmd[2]=root cmd[3]=machine cmd[4]=rsync cmd[5]=--server cmd[6]=--daemon cmd[7]=.
opening connection using: ssh -l root machine rsync --server --daemon . (8 args)
msg checking charset: ANSI_X3.4-1968
[sender] safe_read(5)=0
rsync: did not see server greeting
[sender] _exit_cleanup(code=5, file=main.c, line=1635): entered
rsync error: error starting client-server protocol (code 5) at main.c(1635) [sender=3.1.1pre1]
[sender] _exit_cleanup(code=5, file=main.c, line=1635): about to call exit(5)
[sender] sending MSG_ERROR_EXIT with exit_code 5
[sender] send_msg_int(86, 5)
So rsync is run at the remote end but doesn't answer with the server
greeting the client expects.
>On 02/14/2014 06:34 AM, Carlos Carvalho wrote:
>> Kevin Korb (kmk at sanitarium.net) wrote on 13 February 2014 21:47:
>>> modules are defined in an rsyncd.conf file. That file needs to
>>> be in the home dir of the user.
>>
>> You mean the config file must be called "rsyncd.conf" instead of
>> "module"? That'd be easy to solve but unfortunately it didn't work.
>> I changed the name, put the following in it
>>
>> [module] path = /path/to/home/transfer
>>
>> and I still get the same "did not see server greeting" error.
>>
>>> On 02/13/2014 08:38 PM, Carlos Carvalho wrote:
>>>> I'm trying to transfer something to another machine launching a
>>>> once-only "daemon" through ssh with this command:
>>>>
>>>> rsync -avv -e "ssh -l user" ./orig/ machine::module/
>>>>
>>>> where "module" is the name of a file in the home dir of user
>>>> with the following:
>>>>
>>>> path = /path/to/home/transfer
>>>>
>>>> The ssh connection works without passphrase. This is the
>>>> error:
>>>>
>>>> opening connection using: ssh -l user machine rsync --server
>>>> --daemon . (8 args) rsync: did not see server greeting rsync
>>>> error: error starting client-server protocol (code 5) at
>>>> main.c(1635) [sender=3.1.1pre1]
More information about the rsync
mailing list