Uploaded image for project: 'Percona XtraDB Cluster'
  1. Percona XtraDB Cluster
  2. PXC-2127

PXC shutdown hangs when pool-of-threads is set

    Details

    • Type: Bug
    • Status: Done
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 5.7.21-29.26
    • Fix Version/s: 5.7.22
    • Component/s: None
    • Security Level: Public Bug
    • Labels:

      Description

      Tested on latest PXC (5.7.21), when pool-of-threads is set and there are open connections inside MySQL shutdown hangs.

      How to repeat:

      1) Install PXC 5.7.21 and add following option to mysqld section:

      [mysqld]
      thread_handling=pool-of-threads

      No other options is needed besides regular wsrep configuration. It was also tested without using provider option and the issue does not happen.

      2) Bootstrap the node

      $ systemctl start mysql@bootstrap.service

      3) Connect to mysql and keep this session connected

      $ mysql -u root -p
      Enter password:
      Welcome to the MySQL monitor. Commands end with ; or \g.
      Your MySQL connection id is 12
      Server version: 5.7.21-20-57-log Percona XtraDB Cluster (GPL), Release rel20, Revision 1702aea, WSREP version 29.26, wsrep_29.26
      ...

      4) Use another terminal to shutdown MySQL

      $ mysqladmin -u root -p shutdown
      Enter password:

      Shutdown hangs and the error log shows following lines:

      2018-06-01T22:35:47.875606Z 0 [Warning] /usr/sbin/mysqld: Forcing close of thread 11 user: 'root'

      2018-06-01T22:35:47.875624Z 9 [Note] WSREP: applier thread exiting (code:6)
      2018-06-01T22:35:47.875672Z 10 [Note] WSREP: applier thread exiting (code:6)
      2018-06-01T22:35:47.875753Z 4 [Note] WSREP: applier thread exiting (code:6)
      2018-06-01T22:35:47.875790Z 5 [Note] WSREP: applier thread exiting (code:6)
      2018-06-01T22:35:47.875966Z 6 [Note] WSREP: applier thread exiting (code:6)
      2018-06-01T22:35:47.876113Z 3 [Note] WSREP: applier thread exiting (code:6)
      2018-06-01T22:35:47.876201Z 7 [Note] WSREP: applier thread exiting (code:6)
      2018-06-01T22:35:49.875879Z 0 [Note] WSREP: Waiting for active wsrep applier to exit
      2018-06-01T22:35:49.876086Z 1 [Note] WSREP: rollbacker thread exiting
      2018-06-01T22:35:49.876704Z 0 [Note] Giving 1 client threads a chance to die gracefully
      2018-06-01T22:35:49.876725Z 0 [Note] Shutting down slave threads
      2018-06-01T22:35:51.876959Z 0 [Note] Forcefully disconnecting 1 remaining clients
      2018-06-01T22:35:51.877066Z 0 [Warning] /usr/sbin/mysqld: Forcing close of thread 11 user: 'root'

      2018-06-01T22:35:51.877096Z 0 [Note] Event Scheduler: Purging the queue. 0 events

      Please find attached pt-pmp command output.

        Attachments

          Expenses

            Activity

              People

              • Assignee:
                kenn.takara Kenn Takara
                Reporter:
                juan.arruti Juan Arruti
              • Votes:
                1 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 4 days, 6 hours
                  4d 6h