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

safe_mutex: Found wrong usage of mutex 'LOCK_thd_data' and 'LOCK_plugin'

    XMLWordPrintable

Details

    • Bug
    • Status: Confirmed (View Workflow)
    • Major
    • Resolution: Unresolved
    • 11.3
    • 11.3
    • None

    Description

      Issue initially observed during testing of MDEV-28856, but present in trunk also:

      preview-11.3-preview a4031e4c051d4fc69f466a5678ceb5d3598bf525 (Debug)

      safe_mutex: Found wrong usage of mutex 'LOCK_thd_data' and 'LOCK_plugin'
      Mutex currently locked (in reverse order):
      LOCK_plugin                       /test/git-bisect/preview-11.3-preview_MDEV-28856_patched_dbg/sql/sql_plugin.cc  line 2481
      LOCK_thd_data                     /test/git-bisect/preview-11.3-preview_MDEV-28856_patched_dbg/sql/sql_class.h  line 3967
      LOCK_thd_kill                     /test/git-bisect/preview-11.3-preview_MDEV-28856_patched_dbg/sql/sql_class.h  line 3966
      

      The issue can be seen either during normal operation, or during SHUTDOWN. Possibly these are different issues leading to the same outcome.
      The issues is highly sporadic, yet regularly seen. Testcase reduction has proven to be very difficult. However, a single occurrence reduced to this SHUTDOWN-based testcase:

      INSTALL PLUGIN spider SONAME 'ha_spider.so';
      CREATE TABLE t (c INT) ENGINE=Spider;
      SET max_session_mem_used=8192;
      UNINSTALL SONAME 'ha_spider';
      SHUTDOWN;
      

      This testcase may not be representative of all issues and should not be taken as a typical example, as this issue is during SHUTDOWN and reduced readily compared with the other sporadic occurrences, which do not reduce. Still, it may provide an indication in the code as to the actual bug(s).

      Attachments

        Activity

          People

            ycp Yuchen Pei
            Roel Roel Van de Paar
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

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