Loading ...
Sorry, an error occurred while loading the content.

Postfix mailbox_size_limit var overflow?

Expand Messages
  • Tim Eberhardt
    Hello! I have a weird problem. This weekend I upgraded my gentoo linux box (glibc 2.11 to 2.12, postfix 2.7.4 to 2.8.4 ...). I didn t noticed any problems
    Message 1 of 4 , Aug 30, 2011
    • 0 Attachment
      Hello!

      I have a weird problem. This weekend I upgraded my gentoo linux box (glibc
      2.11 to 2.12, postfix 2.7.4 to 2.8.4 ...). I didn't noticed any problems right
      after the upgrade. A bit later I recompiled gcc because of the changed system
      libs. The next day I noticed that i can not receive mail and I saw these error
      in my logs:

      Aug 30 21:03:07 hostname postfix/local[24231]: fatal: bad numerical
      configuration: mailbox_size_limit = 4294967296
      Aug 30 21:03:08 hostname postfix/master[2303]: warning: process
      //usr/lib64/postfix/local pid 24231 exit status 1
      Aug 30 21:03:08 hostname postfix/master[2303]: warning:
      //usr/lib64/postfix/local: bad command startup -- throttling

      I didn't changed anything on my connfiguration. Postconf says:

      # postconf -n | grep mailbox_size_limit
      mailbox_size_limit = 4294967296

      I tried reducing the number which worked and the errors siappeared:

      # postconf -n | grep mailbox_size_limit
      mailbox_size_limit = 2000000000

      What could be the cause to this? Is this a problem of my system or a postfix
      bug in combination with newer glibc/gcc? Beside this issue my system is
      running fine with all services on it. Any ideas?


      some gentoo system info:

      Portage 2.2.0_alpha51 (default/linux/amd64/10.0, gcc-4.4.5, glibc-2.12.2-r0,
      3.0.3-gentoo x86_64)
      =================================================================
      System uname: Linux-3.0.3-gentoo-x86_64-Dual-Core_AMD_Opteron-tm-
      _Processor_1210-with-gentoo-2.0.3
      Timestamp of tree: Tue, 30 Aug 2011 01:00:01 +0000
      ccache version 2.4 [enabled]
      app-shells/bash: 4.1_p9
      dev-java/java-config: 2.1.11-r3
      dev-lang/python: 2.7.1-r1, 3.1.3-r1
      dev-util/ccache: 2.4-r9
      dev-util/cmake: 2.8.1-r2
      dev-util/pkgconfig: 0.26
      sys-apps/baselayout: 2.0.3
      sys-apps/openrc: 0.8.3-r1
      sys-apps/sandbox: 2.5
      sys-devel/autoconf: 2.68
      sys-devel/automake: 1.10.3, 1.11.1
      sys-devel/binutils: 2.21.1-r1
      sys-devel/gcc: 4.4.5
      sys-devel/gcc-config: 1.4.1-r1
      sys-devel/libtool: 2.4-r1
      sys-devel/make: 3.82
      sys-kernel/linux-headers: 2.6.39 (virtual/os-headers)
      sys-libs/glibc: 2.12.2
      CBUILD="x86_64-pc-linux-gnu"
      CFLAGS="-march=native -O2 -pipe"
      CHOST="x86_64-pc-linux-gnu"
      CXXFLAGS="-march=native -O2 -pipe"
      LDFLAGS="-Wl,-O1 -Wl,--as-needed"
      MAKEOPTS="-j3"


      Best regards,

      Tim
    • Brian Evans - Postfix List
      ... According to the sources (2.8.4 as a reference), mailbox_size_limit is a signed 32-bit integer. (On x86(_64) arch) global/mail_params.h 580:extern
      Message 2 of 4 , Aug 30, 2011
      • 0 Attachment
        On 8/30/2011 3:23 PM, Tim Eberhardt wrote:
        > # postconf -n | grep mailbox_size_limit
        > mailbox_size_limit = 4294967296
        >
        > I tried reducing the number which worked and the errors siappeared:
        >
        > # postconf -n | grep mailbox_size_limit
        > mailbox_size_limit = 2000000000
        >
        > What could be the cause to this? Is this a problem of my system or a postfix
        > bug in combination with newer glibc/gcc? Beside this issue my system is
        > running fine with all services on it. Any ideas?
        >

        According to the sources (2.8.4 as a reference),
        mailbox_size_limit is a signed 32-bit integer. (On x86(_64) arch)
        <code>
        global/mail_params.h
        580:extern int var_mailbox_limit;
        </code>

        This limits the integer to 2,147,483,647.
        Even if it was unsigned, your initial value is over the 4,294,967,295
        limit of an unsigned Int.

        If you want large limits, use a different delivery agent that supports
        it. (Example: Dovecot's deliver(1.x)/dovecot-lda(2.x))
      • Tim Eberhardt
        ... Thanks for clarification Brian! The weird thing is that I use this setting since ~3-4 years now and never ran into trouble. Was there a change in 2.8?
        Message 3 of 4 , Aug 30, 2011
        • 0 Attachment
          Am Dienstag, 30. August 2011, 16:08:35 schrieb Brian Evans - Postfix List:
          > According to the sources (2.8.4 as a reference),
          > mailbox_size_limit is a signed 32-bit integer. (On x86(_64) arch)
          > <code>
          > global/mail_params.h
          > 580:extern int var_mailbox_limit;
          > </code>
          >
          > This limits the integer to 2,147,483,647.
          > Even if it was unsigned, your initial value is over the 4,294,967,295
          > limit of an unsigned Int.

          Thanks for clarification Brian!

          The weird thing is that I use this setting since ~3-4 years now and never ran
          into trouble. Was there a change in 2.8?
        • Brian Evans - Postfix List
          ... This is because it appears your value overflowed to ZERO. Wietse appears to have changed the parse function between 2.7 and 2.8. (file
          Message 4 of 4 , Aug 30, 2011
          • 0 Attachment
            On 8/30/2011 4:32 PM, Tim Eberhardt wrote:
            > Am Dienstag, 30. August 2011, 16:08:35 schrieb Brian Evans - Postfix List:
            >> According to the sources (2.8.4 as a reference),
            >> mailbox_size_limit is a signed 32-bit integer. (On x86(_64) arch)
            >> <code>
            >> global/mail_params.h
            >> 580:extern int var_mailbox_limit;
            >> </code>
            >>
            >> This limits the integer to 2,147,483,647.
            >> Even if it was unsigned, your initial value is over the 4,294,967,295
            >> limit of an unsigned Int.
            > Thanks for clarification Brian!
            >
            > The weird thing is that I use this setting since ~3-4 years now and never ran
            > into trouble. Was there a change in 2.8?
            This is because it appears your value overflowed to ZERO.

            Wietse appears to have changed the parse function between 2.7 and 2.8.
            (file src/global/mail_conf_int.c)

            This is what is alerting you when you go over the value of signed int on
            your architecture.

            Brian
          Your message has been successfully submitted and would be delivered to recipients shortly.