47D85D49.1020907@net1.cc 47D8DD17.1000104@mbaierl.com Message-ID: e2b4b189f5ab92f06b2d0f9cc856c998@ihug.co.nz X-Sender: roundcube-maint@ihug.co.nz Received: from [203.109.131.1] (lo0.akl-newton-corpfw1.ihug.net) (login=martin.kealey@ihug.co.nz) by webmail.ihug.co.nz (running ihug Webmail/0.1b) via TCP with HTTP/1.1 id e2b4b189f5ab92f06b2d0f9cc856c998@ihug.co.nz; Fri, 14 Mar 2008 15:54:41 +1300 User-Agent: ihug Webmail/0.1b Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit
On Thu, 13 Mar 2008 08:51:51 +0100, Michael Baierl mail@mbaierl.com wrote:
BUT why should a PHP app take care of sending mails if you have Sendmail on the computer?
This whole discussion has gone off on a tangent because of this comment.
What causes the memory consumption isn't whether we use SMTP or a command line access to a "sendmail" program.
The problems is that none of the "sendmail" type programs, nor any SMTP server, implements "build a MIME-encapsulated message given a list of attachements".
Quite simply, the MTA's responsibility stops with RFC2821, while RFC2822 is the MUA's job; ie, *our* job.
The problem is that the existing functions need to be fed the entire message as an in-memory string, so if you attach a 20 MB file to your message, you need make a single string of about 27 MB. And due to the way memory is managed by PHP, that can translate into a core image in excess of 200 MB. (Think about passing that string from one function to the next, several times, before it gets to "mail()" or equivalent.)
THIS is our problem: before we switched to RoundCube we used to let our users send 20 MB attachments in webmail, but now we don't have 200 MB for every user, so they're complaining about the "downgrade".
-Martin
List info: http://lists.roundcube.net/dev/