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

GLOBAL debug_dbug setting affected by collation_connection=utf16…

Details

    Description

      SET collation_connection=utf16le_general_ci;
      SET GLOBAL debug_dbug='d,any_random_string';
      

      Will add about 8000-11000 lines of debug information to the error log. However,

      SET GLOBAL debug_dbug='d,any_random_string';
      

      Does not. Happens on all 10.2-10.9 debug versions. Tested via CLI only.

      Discussed with bar and marko.

      Attachments

        Activity

          Roel Roel Van de Paar created issue -
          Roel Roel Van de Paar made changes -
          Field Original Value New Value
          Description {code:sql}
          SET NAMES utf8,collation_connection=utf16le_general_ci;
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Will add about 8000-11000 lines of debug information to the error log. However,
          {code:sql}
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Does not. Happens on all 10.2-10.9 debug versions.

          Discussed with [~bar] and [~marko].
          {code:sql}
          SET NAMES utf8,collation_connection=utf16le_general_ci;
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Will add about 8000-11000 lines of debug information to the error log. However,
          {code:sql}
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Does not. Happens on all 10.2-10.9 debug versions. Tested via CLI only.

          Discussed with [~bar] and [~marko].
          marko Marko Mäkelä made changes -
          Description {code:sql}
          SET NAMES utf8,collation_connection=utf16le_general_ci;
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Will add about 8000-11000 lines of debug information to the error log. However,
          {code:sql}
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Does not. Happens on all 10.2-10.9 debug versions. Tested via CLI only.

          Discussed with [~bar] and [~marko].
          {code:sql}
          SET collation_connection=utf16le_general_ci;
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Will add about 8000-11000 lines of debug information to the error log. However,
          {code:sql}
          SET GLOBAL debug_dbug='d,any_random_string';
          {code}
          Does not. Happens on all 10.2-10.9 debug versions. Tested via CLI only.

          Discussed with [~bar] and [~marko].
          Summary GLOBAL debug_dbug setting affected by NAMES setting GLOBAL debug_dbug setting affected by collation_connection=utf16…
          marko Marko Mäkelä made changes -
          Status Open [ 1 ] Confirmed [ 10101 ]
          ralf.gebhardt Ralf Gebhardt made changes -
          Fix Version/s 10.2 [ 14601 ]
          julien.fritsch Julien Fritsch made changes -
          Fix Version/s 10.7 [ 24805 ]
          julien.fritsch Julien Fritsch made changes -
          Fix Version/s 10.3 [ 22126 ]

          The problem happens because Sys_var_dbug::do_check() does not convert the value to utf8.
          The problem is also repeatable with this script:

          SET collation_connection=utf16le_general_ci;
          SET  debug_dbug='d,any_random_string';
          SELECT @@debug_dbug;
          

          +--------------+
          | @@debug_dbug |
          +--------------+
          | d            |
          +--------------+
          

          This method should fix fixed to convert the value, like Sys_var_charptr_base::do_check_string() does.

          bar Alexander Barkov added a comment - The problem happens because Sys_var_dbug::do_check() does not convert the value to utf8. The problem is also repeatable with this script: SET collation_connection=utf16le_general_ci; SET debug_dbug= 'd,any_random_string' ; SELECT @@debug_dbug; +--------------+ | @@debug_dbug | +--------------+ | d | +--------------+ This method should fix fixed to convert the value, like Sys_var_charptr_base::do_check_string() does.
          bar Alexander Barkov made changes -
          issue.field.resolutiondate 2024-04-10 02:39:49.0 2024-04-10 02:39:49.332
          bar Alexander Barkov made changes -
          Fix Version/s 10.5.25 [ 29626 ]
          Fix Version/s 10.6.18 [ 29627 ]
          Fix Version/s 10.11.8 [ 29630 ]
          Fix Version/s 11.0.6 [ 29628 ]
          Fix Version/s 11.1.5 [ 29629 ]
          Fix Version/s 11.2.4 [ 29631 ]
          Fix Version/s 11.4.2 [ 29633 ]
          Fix Version/s 11.5.1 [ 29634 ]
          Fix Version/s 10.4 [ 22408 ]
          Fix Version/s 10.5 [ 23123 ]
          Fix Version/s 10.6 [ 24028 ]
          Resolution Fixed [ 1 ]
          Status Confirmed [ 10101 ] Closed [ 6 ]

          People

            bar Alexander Barkov
            Roel Roel Van de Paar
            Votes:
            0 Vote for this issue
            Watchers:
            5 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.