Bug #102240 | clone plugin initialization fails when partly installed previously | ||
---|---|---|---|
Submitted: | 13 Jan 2021 8:18 | Modified: | 19 Mar 2021 18:14 |
Reporter: | Daniël van Eeden (OCA) | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Clone Plugin | Severity: | S3 (Non-critical) |
Version: | 8.0.21, 8.0.23 | OS: | Any |
Assigned to: | CPU Architecture: | Any |
[13 Jan 2021 8:18]
Daniël van Eeden
[15 Jan 2021 9:27]
MySQL Verification Team
Hello Daniël, Thank you for the report and feedback. I tried to reproduce this issue at my end on 8.0.22, by failed attempt (Bug #102096) but not seeing any entries in mysql.plugin table to trigger the issue as reported(of course manual INSERT will trigger the issue). Do you have any steps to trigger the issue? Please let us know. Thank you! - mysql> SET SESSION explicit_defaults_for_timestamp=OFF; Query OK, 0 rows affected, 1 warning (0.00 sec) mysql> SET SESSION sql_mode='STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_ENGINE_SUBSTITUTION'; Query OK, 0 rows affected (0.00 sec) mysql> SELECT TABLE_NAME FROM information_schema.tables WHERE TABLE_NAME LIKE '%clone%'; Empty set (0.01 sec) mysql> INSTALL PLUGIN clone SONAME 'mysql_clone.so'; ERROR 1123 (HY000): Can't initialize function 'clone'; Plugin initialization function failed. mysql> mysql> SELECT * FROM mysql.plugin WHERE name='clone'; Empty set (0.00 sec) mysql> mysql> -- manually inserting row mysql> insert into mysql.plugin values('clone','mysql_clone.so'); Query OK, 1 row affected (0.00 sec) mysql> INSTALL PLUGIN clone SONAME 'mysql_clone.so'; ERROR 3883 (HY000): Error installing plugin 'clone': got 'Operation not permitted' writing to mysql.plugin mysql> Agree, with your suggestion on "replace|ignore" if the row already exists. regards, Umesh
[18 Jan 2021 8:08]
Daniël van Eeden
The entry in mysql.plugin wasn't inserted by me. This was left behind from a previous attempt to install the plugin that failed.
[20 Jan 2021 13:52]
MySQL Verification Team
Thank you for Daniel. Observed this on 8.0.23 build. regards, Umesh
[20 Jan 2021 13:53]
MySQL Verification Team
-- build cat docs/INFO_SRC commit: c586d55f06bf915d6506e599deb87dbb89f2496a date: 2020-12-10 06:56:16 +0100 build-date: 2020-12-11 07:43:19 +0000 short: c586d55f06b branch: mysql-8.0.23-release MySQL source 8.0.23 -- bring up mysqld rm -rf 102096/ bin/mysqld --initialize-insecure --basedir=$PWD --datadir=$PWD/102096 --log-error-verbosity=3 bin/mysqld_safe --no-defaults --basedir=$PWD --datadir=$PWD/102096 --core-file --socket=/tmp/mysql_ushastry.sock --port=3333 --log-error=$PWD/102096/log.err --mysqlx-port=33330 --mysqlx-socket=/tmp/mysql_x_ushastry.sock --log-error-verbosity=3 --secure-file-priv=/tmp/ 2>&1 & - run from two terminal yes "INSTALL PLUGIN clone SONAME 'mysql_clone.so';UNINSTALL PLUGIN clone;" | bin/mysql -uroot -S /tmp/mysql_ushastry.sock yes "SET GLOBAL explicit_defaults_for_timestamp=OFF;set global sql_mode='STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_ENGINE_SUBSTITUTION';" | bin/mysql -uroot -S /tmp/mysql_ushastry.sock Kill first instance of YES and then again attempt yes "INSTALL PLUGIN clone SONAME 'mysql_clone.so';UNINSTALL PLUGIN clone;" | bin/mysql -uroot -S /tmp/mysql_ushastry.sock - Instantly got yes "INSTALL PLUGIN clone SONAME 'mysql_clone.so';UNINSTALL PLUGIN clone;" | bin/mysql -uroot -S /tmp/mysql_ushastry.sock ERROR 3883 (HY000) at line 1: Error installing plugin 'clone': got 'Operation not permitted' writing to mysql.plugin - checked from CLI mysql> SELECT VERSION(); +-----------+ | VERSION() | +-----------+ | 8.0.23 | +-----------+ 1 row in set (0.00 sec) mysql> SELECT * FROM information_schema.plugins WHERE plugin_name='clone'\G Empty set (0.00 sec) mysql> INSTALL PLUGIN clone SONAME 'mysql_clone.so'; ERROR 3883 (HY000): Error installing plugin 'clone': got 'Operation not permitted' writing to mysql.plugin mysql> SELECT * FROM mysql.plugin WHERE name='clone'; +-------+----------------+ | name | dl | +-------+----------------+ | clone | mysql_clone.so | +-------+----------------+ 1 row in set (0.00 sec)
[19 Mar 2021 18:14]
Paul DuBois
Posted by developer: Fixed in 8.0.24. A clone plugin installation failure could cause subsequent installation attempts to fail.
[2 Apr 2024 14:36]
Simon Mudd
Related: https://bugs.mysql.com/114529