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

[PATCH] max_connections setting is ignored on start on Debian 8

Details

    • 10.1.9-2

    Description

      $ apt-get install mariadb-server mariadb-client#
      $ echo "max_connections=3000" >> /etc/mysql/conf.d/mariadb.cnf
      $ systemctl restart mysqld
      $ mysql
      Welcome to the MariaDB monitor.  Commands end with ; or \g.
      Your MariaDB connection id is 3
      Server version: 10.1.8-MariaDB-1~jessie mariadb.org binary distribution
       
      Copyright (c) 2000, 2015, Oracle, MariaDB Corporation Ab and others.
       
      Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
       
      MariaDB [(none)]> select @@max_connections\G
      @@max_connections: 214
      1 row in set (0.00 sec)

      Attachments

        Issue Links

          Activity

            Regarding select/poll bugs, for example this one: https://sourceware.org/bugzilla/show_bug.cgi?id=10352 (which is closed, but I believe I've seen active bugs too). I doubt MariaDB is actually affected by this, but didn't check.

            Conversion script as it is now is only meaningful for upgrades, while original report is about clean installation.

            I believe if we add extra pre-script it will further complicate our systemd script, while major purpose of all this effort was simplicity.

            svoj Sergey Vojtovich added a comment - Regarding select/poll bugs, for example this one: https://sourceware.org/bugzilla/show_bug.cgi?id=10352 (which is closed, but I believe I've seen active bugs too). I doubt MariaDB is actually affected by this, but didn't check. Conversion script as it is now is only meaningful for upgrades, while original report is about clean installation. I believe if we add extra pre-script it will further complicate our systemd script, while major purpose of all this effort was simplicity.

            Right, let's increase the limit to 16K.

            There's, of course, an option of chaging to User=root and mysqld --user=mysql, that is, starting mysqld as root. Then it'll be able to change open-files-limit and do memlock too, if requested.

            serg Sergei Golubchik added a comment - Right, let's increase the limit to 16K. There's, of course, an option of chaging to User=root and mysqld --user=mysql , that is, starting mysqld as root. Then it'll be able to change open-files-limit and do memlock too, if requested.

            Fixed by increasing the limit up to 16K.

            svoj Sergey Vojtovich added a comment - Fixed by increasing the limit up to 16K.
            jb-boin Jean Weisbuch added a comment -

            If think that there should be a warning or an error if someone is trying to set the max_connection or table_(open|definition)_cache to a value too high which could lead the server to exhaust all its file descriptors.

            And is there a warning thrown if the open_files_limit is set on my.cnf on a system using the systemd script?

            jb-boin Jean Weisbuch added a comment - If think that there should be a warning or an error if someone is trying to set the max_connection or table_(open|definition)_cache to a value too high which could lead the server to exhaust all its file descriptors. And is there a warning thrown if the open_files_limit is set on my.cnf on a system using the systemd script?

            There're two warnings, which are issued if --log-warnings is set and --open-files-limit is not set:

            Changed limits: max_open_files: %u  max_connections: %ld  table_cache: %ld
            Could not increase number of max_open_files to more than %u (request: %u)

            There is no warning thrown if open_files_limit is set on a system using the systemd script.

            svoj Sergey Vojtovich added a comment - There're two warnings, which are issued if --log-warnings is set and --open-files-limit is not set: Changed limits: max_open_files: %u max_connections: %ld table_cache: %ld Could not increase number of max_open_files to more than %u (request: %u) There is no warning thrown if open_files_limit is set on a system using the systemd script.

            People

              svoj Sergey Vojtovich
              tanj Guillaume Lefranc
              Votes:
              0 Vote for this issue
              Watchers:
              6 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.