trouble connecting to host

7 posts / 0 new
Last post
Anonymous
trouble connecting to host

I connect to my remote linux server using ssh on port 1024 but I can't seem to connect with rsync.

At the command line, when I try typing in:

 rsync -avz --port=1024 <username>@<ip address>::<source file> <destination>

I get:

rsync: server sent "SSH-1.99-OpenSSH_3.9p1" rather than greeting

rsync error: error starting client-server protocol (code 5) at main.c(1171) 

Any ideas what I'm doing wrong? 

itefix
Offline
Last seen: 1 week 6 days ago
Joined: 01.05.2008 - 21:33
Re: trouble connecting to host

Try

rsync -avz -e "ssh -p 1024" <username>@<ip address>::<source file> <destination>

That way, you specify that ssh on port 1024 will be used as the transport mechanism.

eggman2001
Re: trouble connecting to host

Try

rsync -avz -e "ssh -p 1024" @::

That way, you specify that ssh on port 1024 will be used as the transport mechanism.

That seems to get me one step farther (it prompts me for the password) but then I get the following messages:

rsync: connection unexpectedly closed (0 bytes received so far) 

rsync error: error in rsync protocol data stream (code 12) at io.c(434) 

itefix
Offline
Last seen: 1 week 6 days ago
Joined: 01.05.2008 - 21:33
Re: trouble connecting to host

From rsync documentation:

If you need to specify a different remote-shell user, keep in mind that the user@ prefix in front of the host is specifying the rsync-user value (for a module that requires user-based authentication). This means that you must give the '-l user' option to ssh when specifying the remote-shell, as in this example that uses the short version of the --rsh option:

 

    rsync -av -e "ssh -l ssh-user" rsync-user@host::module /dest 

The "ssh-user" will be used at the ssh level; the "rsync-user" will be used to log-in to the "module".

Hope it helps.

eggman2001
Re: trouble connecting to host

Tev -

 Thanks for your help. I'm a bit confused. "ssh-user" I assume is the same username I use to ssh to my server. However, I've never set a "rsync-user". How do I know what that is?

Also, when logging in, I thought that the value just before '@' should be the ssh-user. If I put anything else there, I can't get past the password verification. I'm also confused as to why that documentation says 'module' for where the source is supposed to be...

eggman2001
Re: trouble connecting to host

Just another thought - isn't that for connecting to an rsync daemon? I didn't think that I had to do that.

eggman2001
Re: trouble connecting to host

nevermind. I just realized that I was supposed to use a single colon instead of a double. Thanks!

Topic locked

Release announcements