Results 1 to 10 of 13
Hi,
I am trying to backup my CentOS5.5 webserver to our local windows sbs 2003 server in the office. I have set up ssh and cwrsync on the windows server ...
- 02-17-2011 #1Just Joined!
- Join Date
- Feb 2011
- Location
- London
- Posts
- 7
rsync via ssh from linux to windows sbs 2003 protocol mismatch
Hi,
I am trying to backup my CentOS5.5 webserver to our local windows sbs 2003 server in the office. I have set up ssh and cwrsync on the windows server and have confirmed that the linux server can reach the windows server via the command:
ssh RemoteUser{AT}xxx.xxx.xxx.xxx
It asks for a password and connects fine. However when I run this command to start the backup:
rsync -avz -e ssh home/account/public_html/some/small/directory/ remote_user{AT}xxx.xxx.xxx.xxx:/cygdrive/c/backup/destination/directory/
I get this error after entering the password:
protocol version mismatch -- is your shell clean?
and then it dies.
Has anyone got any ideas?
Thanks
Alex
PS I had to use {AT} instead of the proper character as the forum thought I was posting a URL
- 02-18-2011 #2
This might be related to the SSH version being used on both ends. I would start by looking at the SSH configurations on both machine to ensure they are both using v2.
- 02-22-2011 #3Just Joined!
- Join Date
- Feb 2011
- Location
- London
- Posts
- 7
After more digging it seems it is not about the version of ssh but:
The "is your shell clean" message and the "protocol mismatch"
message are usually caused by having some sort of program
in your .cshrc, .profile, .bashrc or equivalent file that
writes a message every time you connect. Data written
in this way corrupts the rsync data stream. rsync detects this
at startup and produces those error messages.
(via infoscience.co.jp/technical/rsync/original/FAQ.html)
But as I am connecting to a windows machine, I am not quite sure how to deal with this?
- 02-22-2011 #4
How are you authenticating to the server when you do your rsync?
Does the shell do anything other then login?
- 02-23-2011 #5Just Joined!
- Join Date
- Feb 2011
- Location
- London
- Posts
- 7
I log into linux server via root
When I connect to ssh on windows are entering password I get this response:
Microsoft Windows [Version 5.2.3790]
(C) Copyright 1985-2003 Microsoft Corp.
Last login: Tue Feb 22 11:34:21 2011 from 217.196.232.174
C:\Documents and Settings\Administrator.INDIGOCLOTHING\Desktop>
- 02-24-2011 #6
From what I have been reading this might be your issue. The shell is sending information that is causing rsync to choke. Rsyn requires a clean shell. Is there anyway to stop all this output from the shell? sorry I am not a windows person so I don't know how to stop this.
- 02-24-2011 #7Just Joined!
- Join Date
- Feb 2011
- Location
- London
- Posts
- 7
Thanks for your help Robert - that was my conclusion too. I'll keep hunting for the answer.
- 02-24-2011 #8
Just read a web page about changing the prompt permanently in windows.
If you could change the prompt for the rsync user you should be fine.
- 02-25-2011 #9Just Joined!
- Join Date
- Feb 2011
- Location
- London
- Posts
- 7
Thanks - looks useful
- 02-25-2011 #10Just Joined!
- Join Date
- Sep 2009
- Posts
- 5
Have you tried dropping the 'v' verbose switch? and just running:
You could also try reversing the process and mounting the windows directory via CIFS and just rsync the data to the mounted CIFS share.Code:rsync -az -e ssh home/account/public_html/some/small/directory/ remote_user{AT}xxx.xxx.xxx.xxx:/cygdrive/c/backup/destination/directory/


Reply With Quote