Thanks for the prompt reply Daniel... Looks like you're helping out a lot of
people here on the list!
I've checked the server logs - unfortunately nothing was very obvious here.
I'll have to examine them very closely I guess. No duplicate RCPT TO:s, that
I am sure of
My code waits for a response after every SMTP command: I've attached a copy
of that code, it's in PHP...
I could try sending a QUIT and HELO after each message... you think that
will help?
As for the duplicate messages, I've enclosed the two headers below: Message
ID and time are different. Which means they are two separate messages and
not copies. So where does that leave me?
Copy 1:
Return-Path: <[EMAIL PROTECTED]>
Received: from beethoven.nypirg.org ([209.212.75.66])
by imta02a2.registeredsite.com with ESMTP
id
<[EMAIL PROTECTED]>
for <[EMAIL PROTECTED]>; Wed, 25 Apr 2001 16:24:57 -0400
Received: from -string [64.224.1.22] by beethoven.nypirg.org
(SMTPD32-5.01) id AF549342015E; Wed, 25 Apr 2001 16:11:00 EST
Errors-To: [EMAIL PROTECTED]
Return-Path: [EMAIL PROTECTED]
Organization: NYPIRG Straphangers Campaign
From: Straphangers Network <[EMAIL PROTECTED]>
Subject: Your Subway Opinion
Message-Id: <200104251611.SM00354@-string>
Date: Wed, 25 Apr 2001 16:11:18 EST
Copy 2:
Return-Path: <[EMAIL PROTECTED]>
Received: from beethoven.nypirg.org ([209.212.75.66])
by imta02a2.registeredsite.com with ESMTP
id
<[EMAIL PROTECTED]>
for <[EMAIL PROTECTED]>; Wed, 25 Apr 2001 16:29:34 -0400
Received: from -string [64.224.1.22] by beethoven.nypirg.org
(SMTPD32-5.01) id A0715FDE022A; Wed, 25 Apr 2001 16:15:45 EST
Errors-To: [EMAIL PROTECTED]
Return-Path: [EMAIL PROTECTED]
Organization: NYPIRG Straphangers Campaign
From: Straphangers Network <[EMAIL PROTECTED]>
Subject: Your Subway Opinion
Message-Id: <200104251615.SM00354@-string>
Date: Wed, 25 Apr 2001 16:15:55 EST
> -----Original Message-----
> From: Daniel Donnelly [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, April 26, 2001 10:29 AM
> To: Nikhil Goyal
> Subject: Re: [IMail Forum] mailing lists
>
>
> Nikhil,
>
> Well I can think of one method that might cause this, calling the program
> multiple times. Maybe this is the mechanism that causes your troubles. And
> if your code works only when the load is low, maybe it has some timing
> problems. All I'm trying to say is that the reason is still
> unknown and you
> have to consider all possibilities. I do know that IMail won't send a
> message again, once it is accepted. I have seen instances, when
> sending to a
> remote server, when IMail sent multiple times, but the cause was
> the remote
> believing it got the message and sending the acknowledgement,
> which was not
> received by IMail. The problem was the remote, not the IMail server.
>
> The logs will tell the story! Look for duplicates of the RCPT To:
> addresses.
> I suspect that you will find this to be the case.
>
> Does you code look for the responses from the SMTP server when the MAIL
> FROM: and RCPT TO: are sent? I suspect you sent just a simplified
> version of
> your code, but don't know....
>
> You could also try closing the connection after each message, with a QUIT
> and start from the top for each address.
>
> If you can look at the headers of the duplicated messages, check
> the Message
> ID and only if they are the same, would that mean it was a real duplicate.
> With different ID's, they are different messages! Check the time in them,
> too and you may get some idea of the delay between the dups.
>
> Daniel Donnelly
> ________________________________________________________
>
> ----- Original Message -----
> From: "Nikhil Goyal" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, April 25, 2001 4:58 PM
> Subject: RE: [IMail Forum] mailing lists
>
>
> > I've checked the code for loops many times, to no avail. But if the code
> was
> > at fault, wouldn't it ALWAYS generate duplicate mails? How come
> the mails
> go
> > thru okay when the server load is low?
> >
> > Also, I didn't have logs the first time I sent, though I have
> changed that
> > now. Am a little scared of sending out the whole lists again just to
> test...
> > But I will have logs this time
> >
> > Haven't deleted the mail lists from the old setup yet - but not using
> them,
> > like you said. I'm leaving RSET in for now, if it causes no harm it can
> only
> > make things better by clearing up the SMTP buffers right?
> >
> > N
> >
> > > -----Original Message-----
> > > From: [EMAIL PROTECTED]
> > > [mailto:[EMAIL PROTECTED]]On Behalf Of
> Daniel Donnelly
> > > Sent: Wednesday, April 25, 2001 10:16 AM
> > > To: [EMAIL PROTECTED]
> > > Subject: Re: [IMail Forum] mailing lists
> > >
> > >
> > > Nikhil,
> > >
> > > First, you can get rid of the RSET commands as they are doing nothing
> (but
> > > they can stay, too!).
> > >
> > > Second, check the IMail logs to see if your code is really doing what
> you
> > > think it is. I suspect that will show sending to the same
> user multiple
> > > times.
> > >
> > > Have you removed the IMail Lists? You no longer need them (at least
> those
> > > that are replaced by your code).
> > >
> > > Sort of sounds like your code is not working correctly when it is
> getting
> > > the 'next' address, or going through the loop more than once.
> > >
> > > Daniel Donnelly
> > > ________________________________________________________
> > >
> > >
> > > ----- Original Message -----
> > > From: "Nikhil Goyal" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Tuesday, April 24, 2001 11:01 AM
> > > Subject: [IMail Forum] mailing lists
> > >
> > >
> > > > Hello people,
> > > >
> > > > I am running IMail 5.01 on the office network, and need to
> > > regularly send
> > > > mails to our multiple mailing lists.
> > > >
> > > > Recently we upgraded our network to a mySQL database
> storing the email
> > > > addresses, and anytime I wish to send mail to one list, the
> (PHP) code
> > > > generates a list of email addresses dynamically. The code
> now opens a
> > > socket
> > > > on IMail port 25, and sends the body to each recipient,
> SMTP commands
> > > > detailed below:
> > > >
> > > > HELO xxx
> > > > MAIL FROM: (me)
> > > > RCPT TO: (rcpt 1)
> > > > DATA
> > > > (body)
> > > > .
> > > > RSET
> > > > MAIL FROM: (me)
> > > > RCPT TO: (rcpt 2)
> > > > DATA
> > > > (body)
> > > > .
> > > > RSET
> > > > (and so on)
> > > > QUIT
> > > >
> > > > Now the problem is that the recipients of this list get 2
> or sometimes
> > > more
> > > > copies of the email. But it gets stranger. If I am sending mails to
> two
> > > > lists, the people on the first list get one copy of the
> email, but the
> > > list
> > > > I send AFTER this gets two copies. Sometimes people have recd 4
> copies!
> > > >
> > > > So my question is what am I doing wrong? Or better still, what
> > > is the best
> > > > way to send email to a dynamically generated email list?
> > > >
> > > > I'd really appreciate any help,
> > > >
> > > > Nikhil Goyal
> > > >
> > > >
> > > > Please visit http://www.ipswitch.com/support/mailing-lists.html
> > > > to be removed from this list.
> > > >
> > > > An Archive of this list is available at:
> > > > http://www.mail-archive.com/imail_forum%40list.ipswitch.com/
> > > >
> > >
> > >
> > > Please visit http://www.ipswitch.com/support/mailing-lists.html
> > > to be removed from this list.
> > >
> > > An Archive of this list is available at:
> > > http://www.mail-archive.com/imail_forum%40list.ipswitch.com/
> > >
> >
> >
>
>
smtpmailer.inc