Re: Re: Scripts slowing down?
| From: | René Leboeuf | Date: | Thu, 15 May 2008 13:18:16 +0000 |
| Subject: | Re: Re: Scripts slowing down? | ||
| References: | 1 2 3 4 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-274371@lists.php.net to get a copy of this message | ||
Per Jessen a écrit :
René Leboeuf wrote:According to our tests, using SMTP is twice as fast as calling sendmail!The user sending emails is "trusted" by sendmail, and the sending program is located on the sendmail machine.No need to use SMTP then. You should just be calling sendmail to drop the emails into the queue. And that should not be slowing down.
Some of our mailing are +100.000 emails...Mail is sent via PHPMailer. PHPMailer offers to send mail via PHP's mail() function, or by calling the sendmail program or using SMTP. SMTP may use persistent connections or not. All these modes were tested and they all slow down after a while.They _all_ slow down after a while? How many emails are you sending in this way?
It's easily tested. Just generate a script with 10000 calls to the mail() function (send to denis+NNNNN@amoureux.com with NNNNN = random number). If that goes through without slowing down, mail() and your sendmail daemon are not to blame.I had tried with 1000mails and noticed no slow down. I'll try with some more. But if mail() and sendmail are not the problem, what could it be??? Thanks for helping. DJL