[H-GEN] Using Perl scripts to send mail
Rick Phillips
rickp at suntech.net.au
Fri Oct 26 21:58:20 EDT 2007
Edwin,
> On Sat, Oct 27, 2007 at 09:26:28AM +1000, Rick Phillips wrote:
> > uses the perl mail::sendmail to send this mail but finds that it takes
> > six or more seconds to send each email. My server runs qmail which I
>
> Without knowing what the exact path the mail traffic is taking (do
> you do your own delivery, do you drop it at mail relay?) or if it
> happens with everybody or just your tests, or if the DNS reverse
> resolution is going fine, or if the mail is submitted with the
> sendmail command or via an STMP session etc etc etc..., just a quick
> question:
>
I do my own delivery. My server is generally for hosting only and the
half dozen or so clients I have use their own ISP for mail delivery.
Apart from my own mail requirements and that of the CMS's I host, this
is the only user who sends mail directly from my server. For the
curious, this is one of the many web sites which have sprung up to fight
the forced amalgamation of shire councils in Queensland. Volunteers
offer themselves to help however they can through the web site and the
resultant list is used as a vehicle for updated information and news.
It is pukka and not a spammers list. We are probably only talking about
a couple of hundred volunteers. 6-10 seconds x 200 seems like a long
time. I wish he would use a list but he wants this to be as automatic
as possible as he himself is a volunteer.
> Is the six second delay there too when you send the email normally
> from the commandline?
>
If I use "mail" from the command line using a simple (none attachment)
email with as much text as I can type to create "body", there seems to
be no delay at all.
I think the problem is that he is using a for/next loop sending each
email individually. It has been suggested here or elsewhere that the
normal transaction for an individual email using sendmail or qmail is
likely to take 6 seconds or so.
Two suggestions have been made that make sense to me:
1. He send the mail using bcc
2. That he structure his script to hold open the sendmail
transaction (i.e. establish one authentication) and then upload
each email into the already opened session. This is beyond me
and perhaps him as well.
The first suggestion would be the easiest to conduct.
Thanks for your comments
Rick
More information about the General
mailing list