From owner-freebsd-questions@FreeBSD.ORG Mon Nov 17 02:04:10 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 37F8F1065670 for ; Mon, 17 Nov 2008 02:04:10 +0000 (UTC) (envelope-from eculp@casasponti.net) Received: from ns2.bafirst.com (72-12-2-19.static.networktel.net [72.12.2.19]) by mx1.freebsd.org (Postfix) with ESMTP id DE9E48FC08 for ; Mon, 17 Nov 2008 02:04:09 +0000 (UTC) (envelope-from eculp@casasponti.net) Received: from casasponti.net ([201.155.7.3]) by ns2.bafirst.com with esmtp; Sun, 16 Nov 2008 20:04:08 -0600 id 000D51D5.4920D118.00009229 Received: from localhost (localhost [127.0.0.1]) (uid 80) by casasponti.net with local; Sun, 16 Nov 2008 20:03:56 -0600 id 00130C5A.4920D10C.00005B08 Received: from dsl-189-190-24-60.prod-infinitum.com.mx (dsl-189-190-24-60.prod-infinitum.com.mx [189.190.24.60]) by intranet.casasponti.net (Horde Framework) with HTTP; Sun, 16 Nov 2008 20:03:56 -0600 Message-ID: <20081116200356.17qwm4xct6sgocgww@intranet.casasponti.net> Date: Sun, 16 Nov 2008 20:03:56 -0600 From: eculp@casasponti.net To: Jeremy Chadwick References: <20081116094339.17qwm4xct6bkwsc4w@intranet.casasponti.net> <20081116161817.GA5749@icarus.home.lan> In-Reply-To: <20081116161817.GA5749@icarus.home.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable User-Agent: Internet Messaging Program (IMP) H3 (5.0-cvs) X-Remote-Browser: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.1.18) Gecko/20081114 Firefox/2.0.0.18 X-IMP-Server: 201.155.7.3 X-Originating-IP: 189.190.24.60 X-Originating-User: eculp@casasponti.net Cc: freebsd-questions@freebsd.org Subject: Re: How can rsync with ssh be used on a non standard ssh port 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: Mon, 17 Nov 2008 02:04:10 -0000 Jeremy Chadwick escribi=F3: > On Sun, Nov 16, 2008 at 09:43:39AM -0600, eculp@casasponti.net wrote: >> Test example. >> >> I need to sync a directory from my machine to another that is using port >> 722 rather than 22. I can use ssh -pm722, scp -P 722 fine but I prefer >> rsync for the backup due to configuration flexibility. The man says: >> >> rsync [OPTION...] SRC... rsync://[USER@]HOST[:PORT]/DEST >> >> Which I translate to something like: >> >> rsync -avz /almacen/testDir rsync://backupMachine.com:722/backup/ >> >> but I get the following: >> >> rsync: server sent "SSH-2.0-OpenSSH_5.1p1 FreeBSD-20080901" rather than >> greeting >> rsync error: error starting client-server protocol (code 5) at >> main.c(1504) [sender=3D3.0.4] >> >> I've tried variants to the point of no return. Help would be appreciated= . > > Check out the -e flag for rsync. There are examples of how to use this > inside of the rsync(1) man page. I can't believe I missed that. Unfortunately I found the other first. =20 Just for the record. a simple: rsync -avze 'ssh -p 722' /almacen/TestDir backupMachine.com:/backup/ worked as expected. Thanks, ed P.S. I also apologize to the list for sending two emails in the =20 morning. I thought I had canceled the first but yet another error. I =20 shouldn't work on Sundays ;) > > -- > | Jeremy Chadwick jdc at parodius.com | > | Parodius Networking http://www.parodius.com/ | > | UNIX Systems Administrator Mountain View, CA, USA | > | Making life hard for others since 1977. PGP: 4BD6C0CB | > >