Bug #68915 seperate undo log from system log cause innodb plugin can not load by mysql
Submitted: 10 Apr 2013 8:39 Modified: 19 Jul 2013 17:51
Reporter: h h Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Documentation Severity:S2 (Serious)
Version:MySQL5.6 OS:Linux
Assigned to: Bugs System CPU Architecture:Any
Tags: innodb, undo

[10 Apr 2013 8:39] h h
Description:
i am testing new feature about seperate undo log in mysql 5.6,and find
that the mysqld can not load innodb plugin

How to repeat:
install mysql5.6
create database using mysql_install_db
create seperate directory for undo log
change directory owner to user mysql

modify my.cnf file add following info

innodb_undo_directory=/data/mysql_undo
innodb_undo_logs=1
innodb_undo_tablespaces=4

and restart mysqld ,you will find error information in error log

2013-04-10 16:31:41 28685 [ERROR] Plugin 'InnoDB' init function returned error.
2013-04-10 16:31:41 28685 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2013-04-10 16:31:41 28685 [ERROR] Unknown/unsupported storage engine: InnoDB
2013-04-10 16:31:41 28685 [ERROR] Aborting

2013-04-10 16:31:41 28685 [Note] Binlog end
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'partition'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'ARCHIVE'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'BLACKHOLE'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_FT_INSERTED'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_METRICS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_CMPMEM'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_CMP'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_LOCKS'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'INNODB_TRX'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'CSV'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'MEMORY'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'MyISAM'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'MRG_MYISAM'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'sha256_password'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'mysql_old_password'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'mysql_native_password'
2013-04-10 16:31:41 28685 [Note] Shutting down plugin 'binlog'
2013-04-10 16:31:41 28685 [Note] /data/mysql56/bin/mysqld: Shutdown complete
[10 Apr 2013 13:21] MySQL Verification Team
In your case you had to do this initially:

mysql_install_db --innodb_undo_directory=/data/mysql_undo 
--innodb_undo_logs=1 --innodb_undo_tablespaces=4

But you didn't, so now you have to remove the existing ibdata* and/or ib_logfile* in order to change this setting since mysql_install_db already created the innodb subsystem with other settings.

I don't think that it is very obvious from the docs though.
Especially since there are InnoDB tables in the `mysql` database, so if you want to trash the innodb subsystem, you first have to convert the innodb tables to myisam, then re-initialize innodb subsystem, and finally convert the ones in `mysql` back to innodb that you converted to myisam.

http://dev.mysql.com/doc/refman/5.6/en/innodb-performance.html#innodb-undo-tablespace
[19 Jul 2013 17:51] Bugs System
Revised information to make it more clear that the "separate tablespace for undo log" feature must be enabled when the instance is initialized. Also added information about & a link to the transportable tablespace copy procedure, which could be used to transport existing tables to a newly configured MySQL instance.  

The revised content should appear soon, in the next published documentation build. 

http://dev.mysql.com/doc/refman/5.6/en/innodb-performance.html#innodb-undo-tablespace
http://dev.mysql.com/doc/refman/5.7/en/innodb-performance.html#innodb-undo-tablespace

Thank you for the bug report.