Fix: Postfix File too big error

Valic —  March 13, 2013 — 1 Comment

I was looking in my server logs and I’ve found an error from my Postfix Mail Server. That appeared when I wanted to send a 10MB backup trough mail. The error was found in /var/log/mail.err file and looks like this:

postfix/postdrop[197353]: warning: uid=0: File too large
postfix/sendmail[197352]: fatal: root(0): message file too big

To check the default attachments size settings of Postfix use the following command:

# postconf -d | grep size
berkeley_db_create_buffer_size = 16777216
berkeley_db_read_buffer_size = 131072
body_checks_size_limit = 51200
bounce_size_limit = 50000
header_size_limit = 102400
mailbox_size_limit = 51200000
message_size_limit = 10240000
tcp_windowsize = 0

As you can see the Postfix default value for a mailbox size is 51200000 bytes and max message size is 10240000 bytes.
To fix this issue the maximum outgoing message size needs to be increased as well as the mailbox size.
By entering the following commands we will set unlimited for both, mailbox size and max message size:

postconf -e mailbox_size_limit=0
postconf -e message_size_limit=0

We need yo restart the Postfix server:

/etc/init.d/postfix restart
[ ok ] Stopping Postfix Mail Transport Agent: postfix.
[ ok ] Starting Postfix Mail Transport Agent: postfix.

Valic

Posts Twitter Facebook

Editor in Chief at Debian-Tutorials, Linux enthusiast.

One response to Fix: Postfix File too big error

  1. Thanks for the detailed instructions! Saved my day.

Leave a Reply