Someone finally pulled out the math for the full message size limit formula.
So in case any of you were interested in that topic a week ago, here it is: > Simon White wrote: > > 27-Jan-03 at 16:51, [EMAIL PROTECTED] > > ([EMAIL PROTECTED]) wrote : > > > > > > the 15.5MB file in fact was 22MB. smtp seems to produce a nice large > > > overhead. > > > > No, it's Base64 encoding that creates overhead. All email actually > > happens in ASCII... > > > > 15.5*4/3 = 20.66 + headers and suchlike will bring it up to around 21, > > 22 Meg. > > > The 'exact' formula would be to add additional cr/lf for every 40 encoded > bytes, which would result in: > enc_size = orig_size * 4 / 3 + orig_size / 20 > which equals to > enc_size = orig_size * 1.383 > > I've found that using a base64 multiplier of 1.4 mostly fits, and personally > use 1.5 for calculating the message_size_limit parameter. > > 15.5 * 1.4 = 21.7 MB estimated encoded size > 15.5 * 1.5 = 23.25 MB estimated message_size_limit to let it go through. > > Thomas > As usual, they forgot to mention that 1MB = 2^20. If you enter your message_size_limit in bytes this is a very important thing. To expand the calculation for this: Estimated encoded size: 15.5 * 1.4 = 21.7 MB = 22754100 Estimated message_size_limit to let it go through: 15.5 * 1.5 = 23.25 MB = 24379392 --Eric
