Campaign Sent Multiple Times .. (SMTP Error)

This is the message in my log, probably for all subscribers to the list -

Error sending email to aaaa@zz-security.co.uk SMTP Error: data not accepted.SMTP server error: DATA END command failed

The message would be fine because it causes the failing email to be requeued, However it is not so fine in this case because when I look in the mail log on my server I can see that each of the failing messages did not actually fail, they were sent - And resent many times …

We have run phpList for about 7 years, the problem only started a few days ago when I installed the new phpList. This was a complete new install, I just migrated the list of subscribers.

Can someone give some insight into this problem

Many Thanks - Chris.

Hi Chris,

How did you move the settings over to the new install… did you just use the old config.php, or did you edit the new one and update the settings for the old version?

It’s better if you use the new config.php, and change the settings to match the old one.

in particular, this needs to be ‘mysqli’

# select the database module to use
# anyone wanting to submit other database modules is
# very welcome!
$database_module = "mysqli.inc";

Lastly, it appears that the mailing script is not seeing the end of the smtp dialog. The receiving server accepts the message, but since phpList doesn’t see the smtp ‘end’, it thinks the message wasn’t sent, and requeues it. Over and over.

Hi,

 just ran another test and its doing the same - sending multiple times to some email addresses - We set up a test using just a subset of the failing email addresses - It sent 20 times in about 3 minutes to one of the email addreses - By the way some of the failing emails were to 'catchall' email servers - IE. they do not respond to received emails but I guess thats not important.

I run my own apache server and it processes several thousand emails / day maybe more, and has not changed since we upgraded to the current version of PHPlist …

My config.php does not contain a reference to the DB, I will add $database_module = “mysqli.inc” to see what happens, but my ‘simple’ logic tells me that because there is no problem with most emails this might not be the answer.

We would not be unhappy if it just sent emails once and did not bother with retrying the failed ones at least until the problem is solved, any one know where to look in the code ?

Regards, Chris.

Not sure about the last post somthing went wrong - Here it is again –

I just ran another test and its doing the same - sending multiple times to some email addresses - We set up a test using just a subset of the failing email addresses - It sent 20 times in about 3 minutes to one of the email addreses - By the way some of the failing emails were to ‘catchall’ email servers - IE. they do not respond to received emails but I guess thats not important.

I run my own apache server and it processes several thousand emails /
day maybe more, and has not changed since we upgraded to the current
version of PHPlist …

My config.php does not contain a reference to the DB, I will add
$database_module = “mysqli.inc” to see what happens, but my 'simple’
logic tells me that because there is no problem with most emails this
might not be the answer.

We would not be unhappy if it just sent emails once and did not
bother with retrying the failed ones at least until the problem is
solved, any one know where to look in the code ?

Regards, Chris.

@Info I think that the difficulty is knowing whether a failure on sending should be retried or not. phplist doesn’t really have a way of recording that “send failed but do not retry”. You would need to treat any send failure as if it was successful.

The code is in file admin/actions/processqueue.php
Look for this statement, around line 1110

$success = sendEmail($messageid, $useremail, $userhash,
    $htmlpref); // $rssitems Obsolete by rssmanager plugin

To make failures appear successful you would need to set $success to be true.

Hi Duncanc,

             did that and it appears to have solved the problem - I don't really know what the implications of this change are can you fill me in,  or should I say elucidate ?

Many Thanks,

               Chris Coleman.

@Info The effect of the change is for the sending of all emails to appear to work, so ignoring the smtp errors that you are getting.

Of course, if there were some genuine errors then those too will be ignored. But bounces should not be affected.

Again thanks for that and it does seem to work we have just sent out a campaign to 3000 or so members with no duplication.

However I am convinced that something is not as it should be, when i look in the bounces mailbox I can see about 500 bounces (some from a pevious Newsletter) but PHPlist does not get to them. There’s no error message and the bounce mailbox is defined, I have attempted various settings -

$bounce_mailbox_host = ‘localhost’; and ‘mail.xxx.co.uk
$bounce_mailbox_user = ‘bounces@xxx.co.uk’;
$bounce_mailbox_password = ‘xxxxxxxxxxxxxxx’;
#$bounce_mailbox_port = ‘110/pop3/notls’; and $bounce_mailbox_port = “110/pop3”;

I could try the MBOX settings but prefer to solve this problem it almost definately relates to our origional problem.

I expect that both of the problems we’re seeing are related but cannot at the moment move forward on this.

Can you confirm that PHPlist should display the contents of the bounce mailbox once I select 'Lst Bounces ’ ?

One thing - obviously 110 is a POP3 port - would it be worth trying with an IMAP port ?

Many Thanks.

My problem is similar to this. I upgraded to version 3.4.7 and had the problem with the emails being sent multiple times. So we did the suggested fix from [Campaign Sent Multiple Times … (SMTP Error) We got Phplist to treat every attempt to send an email as being successful, even when it was not. But now I have no statistics on my Active Campaign, and no bounce count.