From owner-freebsd-questions@FreeBSD.ORG Fri Aug 18 17:52:34 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8889916A4E0 for ; Fri, 18 Aug 2006 17:52:34 +0000 (UTC) (envelope-from nalists@scls.lib.wi.us) Received: from mail.scls.lib.wi.us (mail.scls.lib.wi.us [198.150.40.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2B1DF43D4C for ; Fri, 18 Aug 2006 17:52:33 +0000 (GMT) (envelope-from nalists@scls.lib.wi.us) Received: from [172.26.2.238] ([172.26.2.238]) by mail.scls.lib.wi.us (8.13.1/8.13.1) with ESMTP id k7IHqS2r090837; Fri, 18 Aug 2006 12:52:30 -0500 (CDT) (envelope-from nalists@scls.lib.wi.us) Message-ID: <44E5FE5B.30009@scls.lib.wi.us> Date: Fri, 18 Aug 2006 12:52:27 -0500 From: Greg Barniskis User-Agent: Thunderbird 1.5.0.5 (Windows/20060719) MIME-Version: 1.0 To: Lisa Casey References: <004501c6c2e5$01603760$d51a2cd0@lisac> In-Reply-To: <004501c6c2e5$01603760$d51a2cd0@lisac> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: rsync on Freebsd 5.3 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Aug 2006 17:52:34 -0000 Lisa Casey wrote: > Hi, > > I am trying to transfer all files in /var/mail from one Freebsd 5.3 > machine (oldfreebsd.com) to another (newfreebsd.com). I decided to use > rsync for this since it would preserve ownership, permissions, etc. I > made sure rsync was installed on both machines. Neither machine had an > /etc/rsyncd.conf or /etc/rsyncd.motd file. On newfreebsd.com I created > /etc/rsyncd.conf thusly: > > motd file = /etc/rsyncd.motd > max connections = 1 > hosts allow = 208.44.xx.xx > > (The IP address is that of oldfreebsd.com) > > On newfreebsd.com, I created rsyncd.motd with the words Authorized Users > Only in it. > > as a test, I'm just trying to rsync /var/mail/lisa from oldfreebsd.com > to newfreebsd.com. When that works I'll do all of /var/mail/ > > on oldfreebsd.com I cd /var/mail, then type: rsync lisa > newfreebsd.com:/var/mail/ > > and get this: > > connect to host newfreebsd.com port 22: Connection refused > rsync: connection unexpectedly closed (0 bytes read so far) > rsync error: error in rsync protocol data stream (code 12) at io.c(348) > > Anyone know what might be wrong? Or can anyone suggest a better way of > moving these mail boxes? man rsync "Modern" rsync wants to use SSH transport, not rsyncd. That's why it's trying for a connect to port 22 of the remote host, and the connection refusal is due to either an intermediate firewall block, TCP wrappers, etc. or else sshd is simply not running. In this case, newfreebsd.com must be running sshd on accessible on port 22. Otherwise, you'll need to actually get rsyncd running and alter your invocation to use it (on port 873). Simplest, most secure fix is to make sure that newfreebsd.com is running sshd, and that should do it. Put sshd_enable="YES" in /etc/rc.conf, tune /etc/ssh/sshd_config as needed, then start sshd by reboot or manually invoking its startup script. -- Greg Barniskis, Computer Systems Integrator South Central Library System (SCLS) Library Interchange Network (LINK) , (608) 266-6348