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

Updating main.cf Efficiently

Expand Messages
  • Rich Shepard
    I just upgraded from -2.7.1 to -2.8.2. I see there are many changes between my existing main.cf and the new main.cf.default.new. Is there an efficient way to
    Message 1 of 10 , Apr 3 4:04 PM
      I just upgraded from -2.7.1 to -2.8.2. I see there are many changes
      between my existing main.cf and the new main.cf.default.new. Is there an
      efficient way to preserve the specifics of my current main.cf while adding
      the new features in the main.cf.default.new?

      Thanks,

      Rich
    • Wietse Venema
      ... Run this, with the old configuration files in place: # postfix upgrade-configuration Wietse POSTFIX(1)
      Message 2 of 10 , Apr 3 4:08 PM
        Rich Shepard:
        > I just upgraded from -2.7.1 to -2.8.2. I see there are many changes
        > between my existing main.cf and the new main.cf.default.new. Is there an
        > efficient way to preserve the specifics of my current main.cf while adding
        > the new features in the main.cf.default.new?

        Run this, with the old configuration files in place:

        # postfix upgrade-configuration

        Wietse

        POSTFIX(1) POSTFIX(1)

        NAME
        postfix - Postfix control program
        ...
        upgrade-configuration [name=value ...]
        Update the main.cf and master.cf files with information that
        Postfix needs in order to run: add or update services, and add
        or update configuration parameter settings.

        Specify name=value to override and update specific main.cf con-
        figuration parameters.
        ...
      • Rich Shepard
        ... Wietse, Thank you. I m still missing something after doing this: I see smtpd_delay_reject = yes in main.cf.new, but not in main.cf. Did I run the command
        Message 3 of 10 , Apr 3 4:26 PM
          On Sun, 3 Apr 2011, Wietse Venema wrote:

          > Run this, with the old configuration files in place:
          >
          > # postfix upgrade-configuration

          Wietse,

          Thank you. I'm still missing something after doing this: I see
          smtpd_delay_reject = yes in main.cf.new, but not in main.cf. Did I run the
          command incorrectly?

          Rich
        • Sahil Tandon
          ... What is main.cf.new? It is not distributed with Postfix. The parameter setting you mention above is the default, and thus does not even need to appear in
          Message 4 of 10 , Apr 3 4:31 PM
            On Sun, 2011-04-03 at 16:26:13 -0700, Rich Shepard wrote:

            > On Sun, 3 Apr 2011, Wietse Venema wrote:
            >
            > >Run this, with the old configuration files in place:
            > >
            > ># postfix upgrade-configuration
            >
            > Wietse,
            >
            > Thank you. I'm still missing something after doing this: I see
            > smtpd_delay_reject = yes in main.cf.new, but not in main.cf. Did I run
            > the command incorrectly?

            What is main.cf.new? It is not distributed with Postfix. The parameter
            setting you mention above is the default, and thus does not even need to
            appear in main.cf.

            --
            Sahil Tandon <sahil@...>
          • Rich Shepard
            ... Sahil, I did not check the date on the file, so it might be from an earlier upgrade. If I understand you correctly, applying upgrade-configuration should
            Message 5 of 10 , Apr 3 4:39 PM
              On Sun, 3 Apr 2011, Sahil Tandon wrote:

              > What is main.cf.new? It is not distributed with Postfix. The parameter
              > setting you mention above is the default, and thus does not even need to
              > appear in main.cf.

              Sahil,

              I did not check the date on the file, so it might be from an earlier
              upgrade.

              If I understand you correctly, applying upgrade-configuration should be
              all I need to do and parameters such as smtpd_delay_reject = yes should be
              in 2.8.2 without explicit inclusion in main.cf. Yet a colleage of mine still
              has his mail to me rejected before the helo_checks and I thought that I
              needed to set smtpd_delay_reject to yes to resolve the issue.

              I suppose that I can remove main.cf.new and main.cf.default.new, correct?

              Thanks,

              Rich
            • Rich Shepard
              ... OK. Running postconf shows me that stmpd_delay_reject is set to yes. I ll now delete all the *.new files. Many thanks to both of you for the lesson, Rich
              Message 6 of 10 , Apr 3 4:45 PM
                On Sun, 3 Apr 2011, Rich Shepard wrote:

                > If I understand you correctly, applying upgrade-configuration should be
                > all I need to do and parameters such as smtpd_delay_reject = yes should be
                > in 2.8.2 without explicit inclusion in main.cf. Yet a colleage of mine
                > still has his mail to me rejected before the helo_checks and I thought
                > that I needed to set smtpd_delay_reject to yes to resolve the issue.

                OK. Running postconf shows me that stmpd_delay_reject is set to yes. I'll
                now delete all the *.new files.

                Many thanks to both of you for the lesson,

                Rich
              • Sahil Tandon
                ... AFAIK, Postfix has never distributed such files. This must be an artifact of your package management system. ... Like I said, smtpd_delay_reject = yes
                Message 7 of 10 , Apr 3 4:45 PM
                  On Sun, 2011-04-03 at 16:39:15 -0700, Rich Shepard wrote:

                  > On Sun, 3 Apr 2011, Sahil Tandon wrote:
                  >
                  > >What is main.cf.new? It is not distributed with Postfix. The
                  > >parameter setting you mention above is the default, and thus does not
                  > >even need to appear in main.cf.
                  >
                  > Sahil,
                  >
                  > I did not check the date on the file, so it might be from an earlier
                  > upgrade.

                  AFAIK, Postfix has never distributed such files. This must be an
                  artifact of your package management system.

                  > If I understand you correctly, applying upgrade-configuration should
                  > be all I need to do and parameters such as smtpd_delay_reject = yes
                  > should be in 2.8.2 without explicit inclusion in main.cf. Yet a
                  > colleage of mine still has his mail to me rejected before the
                  > helo_checks and I thought that I needed to set smtpd_delay_reject to
                  > yes to resolve the issue.

                  Like I said, 'smtpd_delay_reject = yes' is the *default*, so you do not
                  need to explicitly set it anywhere. Unless you set it to 'no' in your
                  main.cf, you do not have to do anything. To be sure you have the
                  desired setting, see the output of 'postconf smtpd_delay_reject'. And
                  also note that this setting has been the default since well before
                  2.7.2.

                  > I suppose that I can remove main.cf.new and main.cf.default.new,
                  > correct?

                  I would think so, but leaving them there is likely harmless.

                  --
                  Sahil Tandon <sahil@...>
                • Rich Shepard
                  ... Yes, from the last Slackware upgrade. ... Well, then, that s not the problem we re having. Many thanks, Rich
                  Message 8 of 10 , Apr 3 4:48 PM
                    On Sun, 3 Apr 2011, Sahil Tandon wrote:

                    > AFAIK, Postfix has never distributed such files. This must be an artifact
                    > of your package management system.

                    Yes, from the last Slackware upgrade.

                    > And also note that this setting has been the default since well before
                    > 2.7.2.

                    Well, then, that's not the problem we're having.

                    Many thanks,

                    Rich
                  • Noel Jones
                    ... As always, posting logging of the unwanted behavior along with your postconf -n is the best way to get some help. -- Noel Jones
                    Message 9 of 10 , Apr 3 7:08 PM
                      On 4/3/2011 6:48 PM, Rich Shepard wrote:
                      > On Sun, 3 Apr 2011, Sahil Tandon wrote:
                      >
                      >> AFAIK, Postfix has never distributed such files. This must
                      >> be an artifact
                      >> of your package management system.
                      >
                      > Yes, from the last Slackware upgrade.
                      >
                      >> And also note that this setting has been the default since
                      >> well before
                      >> 2.7.2.
                      >
                      > Well, then, that's not the problem we're having.
                      >
                      > Many thanks,
                      >
                      > Rich

                      As always, posting logging of the unwanted behavior along with
                      your "postconf -n" is the best way to get some help.


                      -- Noel Jones
                    • /dev/rob0
                      ... AFAIK the default for smtpd_delay_reject was always yes . ... This was surely not the case; postconf.5.html#smtpd_delay_reject explains that it only
                      Message 10 of 10 , Apr 3 8:05 PM
                        On Sun, Apr 03, 2011 at 04:45:28PM -0700, Rich Shepard wrote:
                        > On Sun, 3 Apr 2011, Rich Shepard wrote:
                        > > If I understand you correctly, applying upgrade-configuration
                        > >should be all I need to do and parameters such as
                        > >smtpd_delay_reject = yes should be in 2.8.2 without explicit
                        > >inclusion in main.cf.

                        AFAIK the default for smtpd_delay_reject was always "yes".

                        > > Yet a colleage of mine still has his mail to me rejected
                        > >before the helo_checks and I thought that I needed to set
                        > >smtpd_delay_reject to yes to resolve the issue.

                        This was surely not the case; postconf.5.html#smtpd_delay_reject
                        explains that it only improves logging, and the chances that a
                        rejection will "stick" with bad clients. If smtpd_delay_reject
                        delayed a rejection, it is ONLY a delay. It was to be rejected
                        anyway.

                        > OK. Running postconf shows me that stmpd_delay_reject is set to
                        > yes. I'll now delete all the *.new files.

                        Wrong solution. The right solution was to overwrite the old files
                        with their *.new equivalents, except for the two which matter, and
                        are handled by "postfix upgrade-configuration": main.cf and
                        master.cf. The others are probably the ones which are there for
                        information and reference. (YMMV, if you have included files of
                        similar names in your configuration.)

                        (I'm familiar with the package build script that Rich is talking
                        about.)
                        --
                        Offlist mail to this address is discarded unless
                        "/dev/rob0" or "not-spam" is in Subject: header
                      Your message has been successfully submitted and would be delivered to recipients shortly.