Available are my fixed sources to mirror 2.3. My base package is not quite
2.3, but the "experimental" one which included some perl5 fixes, used a new
ftp.pl and lchat.pl. Included in my ftp directory is my full mirror
package. You should use all of these files in conjunction.
Note that I've only tested these under Solaris 2.3, Solaris 2.4 and SunOS
4.1.3_U1 (with all known patches at the time). Your experience may be
different.
There were 5 significant changes:
(1) *** SOCKS support:
You can use mirror with a "sockified" perl (called rperl) to go over
firewalls which implement SOCKS so that your mirror machine can be inside
the firewalled environment, not on the DMZ side.
To turn on socks support, you should set the variable
using_socks=true
in the appropriate packages. Otherwise it will default to false.
If you need information on how to build perl5 with socks, see my comments
and my sample config.sh in
ftp://ftp.cs.columbia.edu/pub/ezk/perl5+socks/{README,config.sh}
(2) *** PASV support:
Mirror, ftp.pl, and lchat.pl can use the PASV part of the FTP protocol. To
use it turn on the mirror variable
passive_ftp=true
in the appropriate packages. Otherwise it will default to false.
PASV is really important for ftp-ing using certain proxies such as the socks
version of ftp (known as rftp), for use with firewalls. However PASV can be
used with any (ftp) server which implements it, not necessarily in a
firewalled environment.
(3) *** REMOTE ACCOUNT:
Some new ftp servers allow you to login as anonymous or some other ID, and
use whatever matching password with the ftp login. However, *then* they
prompt you with an extra "account login" prompt. People with SunSolve
support contracts who ftp patches from sunsolve1.sun.com know what I mean.
You can now mirror from such sites by setting the mirror variable
remote_account=myacct/acctpasswd
in the appropriate packages, where "myacct" is your special account name and
"acctpasswd" is the password of that account.
This fix is courtesy of Seth Robertson, a colleague of mine.
(4) *** EXCLUSION OF SOME ERROR MESSAGES:
Sometimes an ftp RETR (retrieve) command fails for reasons that are not very
transient (i.e. trying shortly afterwards will not be different). Most
often I find that remote ftp maintainers would forget to chmod files they
put up for public ftp -- to be world readable. The result of such a "get"
command would be "Permission denied". You can try all you want to contact
these maintainers to get their act together, but it gets boring after a
while (did you ever try to educate everyone to use list-request rather than
"list" for un/subscription requests?)
Until these "chmod" (and other) problems are fixed on the other end, each
time you will try to ftp these files you would get a report generated which
lists these files and the error that they could not be retrieved. It's
annoying to have to see these same errors each day from last night's mirror
log report.
So I've added another variable, which is a regexp of error messages
indicating failure, to parse out of the mirror log output. The variable is
called failed_gets_excl, and I usually set it to
failed_gets_excl=\:\ Permission denied\.$
You can set it to any legal perl regexp.
(5) *** ASSORTED PERL 5 FIXES:
I fixed numerous (but not all) problems which came up with running perl5 -w
(have you ever tried to fix everything that lint complained about... :-)
properly free and nullify the array. Not so in perl5 and I'm not sure why.
The bug caused state to be left from one package to the next during one
invocation of mirror. This resulted in later packages getting corrupt by
removing files they should not have, or attempt to get files that belong to
another package.
Fixed a simple bug which caused the percentage of files to be removed to be
miscalculated.
The appropriate man pages for mirror were updated of course.
=========================================================================== That's it. I hope you find my changes useful. I've been running with these You can find original mirror sources in My modified mirror-2.3 package is in Those interested in the details of my fixes can diff my files against =========================================================================== This file is ftp://ftp.cs.columbia.edu/pub/ezk/mirror-2.3+ezk/README
Erez Zadok.
fixed files on 3 mirror sites for over a week now without problems.
ftp://src.doc.ic.ac.uk/packages/mirror/
ftp://ftp.cs.columbia.edu/pub/ezk/mirror-2.3+ezk/mirror-2.3+ezk.tar.gz
original sources. Please don't ask me any more questions, unless you are a
maintainer of any of the above packages and have "real" questions. Sorry
but I do not have the time for anyone but maintainers (in the hope these
fixes make it to one of the next official releases).
comp.unix.solaris, and comp.lang.perl. Feel free to forward it to other
related lists and newsgroups.
Mobile Computing Lab.
Columbia University Department of Computer Science.
---
after midnight." | Usenet: ...!rutgers!columbia!cs!ezk