Re: making mail() funtion work without sendmail on UNIX systems

From: Date: Fri, 19 Oct 2001 08:48:30 +0000
Subject: Re: making mail() funtion work without sendmail on UNIX systems
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-68313@lists.php.net to get a copy of this message
> > You completely lose the most important feature. A non-blocking mail() > > call which queues the message. Having a web app wait on an smtp delivery > > is crap. Mail should be delivered out of band. > > non-blocking? mail() uses popen() and has to wait for the > execution of /usr/lib/sendmail to terminate AFAIR Yes, but if you have sendmail set up to simply queue the message it comes right back. Sendmail/qmail/postfix then later delivers the message out of band. This is essential if you are sending a lot of mail. Or even if you just want a nice quick web app. > there is no performance penalty when talking to the SMTP > port @localhost, in both cases you have to wait for the > local MTA to accept the message for spooling > (and when localhost is just a relay you gain even more > by talking to the 'real' MTA immediately) > > but SMTP comes without the additional process creation overhead > you have with the current popen("/usr/lib/sendmail ...","r") > solution and you have this overhead for *every* message you send > out while you can send several messages during a single SMTP > session True, smtp delivery to localhost could be useful. But it would be hard to make this the default. I am sure many people do not have an smtpd listening on localhost:25 while most people have an MTA capable of spooling or delivering a message. -Rasmus

« previous php.dev (#68313) next »