Re: two-way synchronization accross a firewall fails

2004-05-24 Thread Paul Slootman
On Thu 20 May 2004, Tim Harsch wrote:
 
 firewall allows ssh connections if inititiated from I to O, but not if the
 other way.
 
 both machines have an /etc/rsyncd.conf of:
 [rt]
  path = /tmp/rsync_test
  comment = Test area
 
 O runs rsync daemon, I initiates a rsync cammnad like
 rsync -rvvv --delete --rsh=ssh O::rt /tmp/rsync_test
 
 which works great, but when flipped and run on machine I, like so:
 rsync -rvvv --delete --rsh=ssh /tmp/rsync_test  O::rt

One thing that strikes me first:
If you're going to use ssh, don't use an rsync daemon
(and hence no :: paths, only : paths).


Paul Slootman
-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: two-way synchronization accross a firewall fails

2004-05-24 Thread Wayne Davison
On Thu, May 20, 2004 at 11:46:35AM -0700, Tim Harsch wrote:
 both machines have an /etc/rsyncd.conf of:
 [rt]
  path = /tmp/rsync_test
  comment = Test area

Note that there is no read only = no, so this area cannot be written
to.  That may well be why the upload command you mentioned failed.  It
is hard to know for sure, though, because the command you use creates
its own rsync daemon, and it doesn't look for the rsyncd.conf file in
/etc, but in the home dir of the user you are using for the ssh
connection.

 O runs rsync daemon, I initiates a rsync cammnad like
 rsync -rvvv --delete --rsh=ssh O::rt /tmp/rsync_test

As Tim said, there's no need to run a separate rsync daemon if you're
using an ssh connection, so skip that part.  However, he fails to point
out that it is possible to use :: with -rsh=ssh if you want some of
the features of daemon mode (such as named directories or logging) but
still want to use ssh (just realize that users can do other copies
besides what is allowed in the config file unless you restrict the
remote commands that ssh allows to be run).

If you just want to transfer the files, simplify to something like this:

  rsync -rvvv --delete --rsh=ssh O:/tmp/rsync_test /tmp

  rsync -rvvv --delete --rsh=ssh /tmp/rsync_test  O:/tmp

Also, you'll probably want -t (unless you don't plan on updating the
files once they're transferred).

..wayne..
-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: two-way synchronization accross a firewall fails

2004-05-21 Thread Tim Harsch
This was somehow related to the fact that I was su'd to root, but not with
root env ie. su --

- Original Message - 
From: Tim Harsch [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, May 20, 2004 11:46 AM
Subject: two-way synchronization accross a firewall fails


 machine O is outside firewall, machine I is inside (machine names changed
to
 protect the innocent :-)

 firewall allows ssh connections if inititiated from I to O, but not if the
 other way.

 both machines have an /etc/rsyncd.conf of:
 [rt]
  path = /tmp/rsync_test
  comment = Test area

 O runs rsync daemon, I initiates a rsync cammnad like
 rsync -rvvv --delete --rsh=ssh O::rt /tmp/rsync_test

 which works great, but when flipped and run on machine I, like so:
 rsync -rvvv --delete --rsh=ssh /tmp/rsync_test  O::rt

 we get
 rsync -rvvv --delete --rsh=ssh /tmp/rsync_test O::rt
 opening connection using ssh O rsync --server --daemon .
 [EMAIL PROTECTED]'s password:
 building file list ...
 [sender] make_file(rsync_test,*,2)
 [sender] expand file_list to 131072 bytes, did move
 [sender] make_file(rsync_test/t,*,2)
 [sender] make_file(rsync_test/core,*,2)
 [sender] clearing per-dir .cvsignore exclude list
 done
 send_file_list done
 send_files starting
 rsync: connection unexpectedly closed (28 bytes read so far)
 rsync error: error in rsync protocol data stream (code 12) at io.c(342)
 _exit_cleanup(code=12, file=io.c, line=342): about to call exit(12)

 -- 
 To unsubscribe or change options:
http://lists.samba.org/mailman/listinfo/rsync
 Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html