rsync and Perl programming

Tim Conway conway at us.ibm.com
Thu May 6 13:34:27 GMT 2004


escape your @.  I don't remember the details, but I know it got chewed up 
by something in a past application.

Tim Conway
Unix System Administration
Contractor - IBM Global Services
desk:3032734776
conway at us.ibm.com




Hi everybody -

I'm trying to write a Perl wrapper for some rsync tasks that need doing. 
  Problem is, there's some sort of odd interaction going on between Perl 
and the daemon mode communication for the rsync client, and I'm at my 
wit's end in trying to figure it out.

Here's the Perl script:

#####################################################
#####################################################
#!/usr/bin/perl
$rsync_cmd = "/usr/local/bin/rsync -a --progress 
--password-file=/usr/local/etc/rsyncd.passwd 
ph34r at localhost::samba/rsynctestfiles /usr/share/smbshare/rsynctestfiles";

$pid = open(PH, "$rsync_cmd 2>&1 |");     # with an openpipe
while (<PH>) {                            # plus a read
         print $_;
}

print "finished\n";


#####################################################





More information about the rsync mailing list