Author Topic: Setting mail maximum attachment size  (Read 1838 times)

Offline kazimk

  • Newbie
  • *
  • Posts: 7
Setting mail maximum attachment size
« on: June 09, 2020, 09:28:04 AM »
Hello,

I want to set max mail attachment size to 25M in roundcube  and configuration is like below. Is there any other thing that I should add to configuration? Any help appretiated.

/etc/postfix/main.cf
message_size_limit = 26214400

/etc/roundcubemail/config.inc.php
$config['max_message_size'] = '25M';

"/etc/php.d/30-user.ini"
post_max_size=25M
max_execution_time=200
upload_max_filesize=25M
memory_limit=256M

Regards.

Offline alec

  • Hero Member
  • *****
  • Posts: 1,363
Re: Setting mail maximum attachment size
« Reply #1 on: June 09, 2020, 10:07:24 AM »
You don't have to rise memory limit. Also note that 25MB attachment will take 33MB in the message (because of Base64 encoding).

Offline kazimk

  • Newbie
  • *
  • Posts: 7
Re: Setting mail maximum attachment size
« Reply #2 on: June 09, 2020, 10:38:20 AM »
Thank you for quick reply. I changed configuration like below and it works.

/etc/postfix/main.cf
message_size_limit = 34603008

/etc/roundcubemail/config.inc.php
$config['max_message_size'] = '33M';

"/etc/php.d/30-user.ini"
post_max_size=33M
max_execution_time=200
upload_max_filesize=33M