Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-11670

Multi instance config bug: main daemon (my.cnf) read config file of second one in conf.d

Details

    • Bug
    • Status: Closed (View Workflow)
    • Blocker
    • Resolution: Fixed
    • 10.1.20
    • 10.4.6
    • Configuration
    • Debian 8 x64

    Description

      To start multiple instances of MariaDB, you added a /lib/systemd/system/mariadb@.service, indicating that we must create config file for the second daemon in /etc/mysql/conf.d/my{instancename}.cnf.

      But this file is read by the main daemon! In /etc/mysql/my.cnf, we found at the bottom:
      !includedir /etc/mysql/conf.d/*

      So the main daemon:

      • reads the port/socket/etc. from my.cnf
      • change those values later when reading my{instancename}.cnf

      I you comment the !includedir and add as many !include /etc/mysql/conf.d/{conf}.cnf you have, it works as expected.

      To my mind, the "clean" way of fixing it si to read those my{instancename}.cnf files from /etc/mysql, and NOT from /etc/mysql/conf.d.

      Attachments

        Issue Links

          Activity

            Worst Jérémie LEGRAND created issue -
            Worst Jérémie LEGRAND made changes -
            Field Original Value New Value
            Description To start multiple instances of MariaDB, you added a {{/lib/systemd/system/mariadb@.service}}, indicating that we must create config file for the second daemon in {{/etc/mysql/conf.d/my{instancename}.cnf}}.

            But this file is read by the main daemon! In /etc/mysql/my.cnf, we found at the bottom:
            {{!includedir /etc/mysql.conf.d/*}}

            So the main daemon:
            * reads the port/socket/etc. from my.cnf
            * change those values later when reading {{my{instancename}.cnf}}

            I you comment the {{!includedir}} and add as many {{!include /etc/mysql/conf.d/{conf}.cnf}} you have, it works as expected.


            To my mind, the "clean" way of fixing it si to read those {{my{instancename}.cnf}} files from {{/etc/mysql}}, and NOT from {{/etc/mysql/conf.d}}.
            To start multiple instances of MariaDB, you added a {{/lib/systemd/system/mariadb@.service}}, indicating that we must create config file for the second daemon in {{/etc/mysql/conf.d/my\{instancename\}.cnf}}.

            But this file is read by the main daemon! In /etc/mysql/my.cnf, we found at the bottom:
            {{!includedir /etc/mysql.conf.d/*}}

            So the main daemon:
            * reads the port/socket/etc. from my.cnf
            * change those values later when reading {{my{instancename}.cnf}}

            I you comment the {{!includedir}} and add as many {{!include /etc/mysql/conf.d/{conf}.cnf}} you have, it works as expected.


            To my mind, the "clean" way of fixing it si to read those {{my{instancename}.cnf}} files from {{/etc/mysql}}, and NOT from {{/etc/mysql/conf.d}}.
            Worst Jérémie LEGRAND made changes -
            Description To start multiple instances of MariaDB, you added a {{/lib/systemd/system/mariadb@.service}}, indicating that we must create config file for the second daemon in {{/etc/mysql/conf.d/my\{instancename\}.cnf}}.

            But this file is read by the main daemon! In /etc/mysql/my.cnf, we found at the bottom:
            {{!includedir /etc/mysql.conf.d/*}}

            So the main daemon:
            * reads the port/socket/etc. from my.cnf
            * change those values later when reading {{my{instancename}.cnf}}

            I you comment the {{!includedir}} and add as many {{!include /etc/mysql/conf.d/{conf}.cnf}} you have, it works as expected.


            To my mind, the "clean" way of fixing it si to read those {{my{instancename}.cnf}} files from {{/etc/mysql}}, and NOT from {{/etc/mysql/conf.d}}.
            To start multiple instances of MariaDB, you added a {{/lib/systemd/system/mariadb@.service}}, indicating that we must create config file for the second daemon in {{/etc/mysql/conf.d/my\{instancename\}.cnf}}.

            But this file is read by the main daemon! In /etc/mysql/my.cnf, we found at the bottom:
            {{!includedir /etc/mysql.conf.d/*}}

            So the main daemon:
            * reads the port/socket/etc. from my.cnf
            * change those values later when reading {{my\{instancename\}.cnf}}

            I you comment the {{!includedir}} and add as many {{!include /etc/mysql/conf.d/\{conf\}.cnf}} you have, it works as expected.


            To my mind, the "clean" way of fixing it si to read those {{my\{instancename\}.cnf}} files from {{/etc/mysql}}, and NOT from {{/etc/mysql/conf.d}}.
            elenst Elena Stepanova made changes -
            Fix Version/s 10.1 [ 16100 ]
            Assignee Sergey Vojtovich [ svoj ]
            elenst Elena Stepanova made changes -
            Labels systemd
            svoj Sergey Vojtovich made changes -
            Assignee Sergey Vojtovich [ svoj ] Vicentiu Ciorbaru [ cvicentiu ]
            svoj Sergey Vojtovich made changes -
            Priority Major [ 3 ] Critical [ 2 ]
            serg Sergei Golubchik made changes -
            Assignee Vicentiu Ciorbaru [ cvicentiu ] Axel Schwenke [ axel ]
            danblack Daniel Black made changes -
            Fix Version/s 10.4 [ 22408 ]
            Fix Version/s 10.1 [ 16100 ]
            danblack Daniel Black made changes -
            Priority Critical [ 2 ] Blocker [ 1 ]
            danblack Daniel Black made changes -
            Fix Version/s 10.4.5 [ 23311 ]
            Fix Version/s 10.4 [ 22408 ]
            serg Sergei Golubchik made changes -
            Fix Version/s 10.4 [ 22408 ]
            Fix Version/s 10.4.5 [ 23311 ]
            ralf.gebhardt Ralf Gebhardt made changes -
            Status Open [ 1 ] In Progress [ 3 ]
            serg Sergei Golubchik made changes -
            Description To start multiple instances of MariaDB, you added a {{/lib/systemd/system/mariadb@.service}}, indicating that we must create config file for the second daemon in {{/etc/mysql/conf.d/my\{instancename\}.cnf}}.

            But this file is read by the main daemon! In /etc/mysql/my.cnf, we found at the bottom:
            {{!includedir /etc/mysql.conf.d/*}}

            So the main daemon:
            * reads the port/socket/etc. from my.cnf
            * change those values later when reading {{my\{instancename\}.cnf}}

            I you comment the {{!includedir}} and add as many {{!include /etc/mysql/conf.d/\{conf\}.cnf}} you have, it works as expected.


            To my mind, the "clean" way of fixing it si to read those {{my\{instancename\}.cnf}} files from {{/etc/mysql}}, and NOT from {{/etc/mysql/conf.d}}.
            To start multiple instances of MariaDB, you added a {{/lib/systemd/system/mariadb@.service}}, indicating that we must create config file for the second daemon in {{/etc/mysql/conf.d/my\{instancename\}.cnf}}.

            But this file is read by the main daemon! In /etc/mysql/my.cnf, we found at the bottom:
            {{!includedir /etc/mysql/conf.d/*}}

            So the main daemon:
            * reads the port/socket/etc. from my.cnf
            * change those values later when reading {{my\{instancename\}.cnf}}

            I you comment the {{!includedir}} and add as many {{!include /etc/mysql/conf.d/\{conf\}.cnf}} you have, it works as expected.


            To my mind, the "clean" way of fixing it si to read those {{my\{instancename\}.cnf}} files from {{/etc/mysql}}, and NOT from {{/etc/mysql/conf.d}}.
            axel Axel Schwenke made changes -
            issue.field.resolutiondate 2019-06-14 13:49:46.0 2019-06-14 13:49:46.365
            axel Axel Schwenke made changes -
            Fix Version/s 10.4.6 [ 23412 ]
            Fix Version/s 10.4 [ 22408 ]
            Resolution Fixed [ 1 ]
            Status In Progress [ 3 ] Closed [ 6 ]
            GeoffMontee Geoff Montee (Inactive) made changes -
            serg Sergei Golubchik made changes -
            Workflow MariaDB v3 [ 78912 ] MariaDB v4 [ 151446 ]

            People

              axel Axel Schwenke
              Worst Jérémie LEGRAND
              Votes:
              2 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.