Bug #48693 Example Plugin disables InnoDB Plugin
Submitted: 11 Nov 2009 17:29 Modified: 11 Nov 2009 20:47
Reporter: Miguel Solorzano Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server: InnoDB Plugin storage engine Severity:S2 (Serious)
Version:5.1.42 OS:Windows (Vista 64-bit)
Assigned to: CPU Architecture:Any

[11 Nov 2009 17:29] Miguel Solorzano
Description:
Compile mysql-5.1 on Windows.
Create a my.ini file like below:

[mysqld]
basedir=c:/dbs/5.1/
datadir=c:/dbs/5.1/data
port=3510
ignore-builtin-innodb
plugin-load=innodb=ha_innodb_plugin.dll
#plugin-load=example=ha_example.dll
log-bin = mydb

Start the server as standalone:

c:\dbs>c:\dbs\5.1\bin\mysqld --defaults-file=c:\dbs\5.1\my.ini --standalone --console
091111 15:12:59 [Note] Plugin 'FEDERATED' is disabled.
InnoDB: The InnoDB memory heap is disabled
InnoDB: Mutexes and rw_locks use Windows interlocked functions
091111 15:12:59  InnoDB: highest supported file format is Barracuda.
091111 15:12:59 InnoDB Plugin 1.0.5 started; log sequence number 44263
091111 15:13:00 [Note] Event Scheduler: Loaded 0 events
091111 15:13:00 [Note] c:\dbs\5.1\bin\mysqld: ready for connections.
Version: '5.1.42-Win X64-log'  socket: ''  port: 3510  Source distribution

Do a "show engines":

c:\dbs>5.1\bin\mysql -uroot --port=3510 --e="show engines;"
+------------+---------+--------------------------------------
| Engine     | Support | Comment
+------------+---------+--------------------------------------
| MEMORY     | YES     | Hash based, stored in memory, useful
| CSV        | YES     | CSV storage engine
| InnoDB     | YES     | Supports transactions, row-level lock
| BLACKHOLE  | YES     | /dev/null storage engine (anything yo
| FEDERATED  | NO      | Federated MySQL storage engine
| MyISAM     | DEFAULT | Default engine as of MySQL 3.23 with
| ARCHIVE    | YES     | Archive storage engine
| MRG_MYISAM | YES     | Collection of identical MyISAM tables
+------------+---------+--------------------------------------

Uncomment the example plugin example engine line in the my.ini file:

c:\dbs>cat 5.1\my.ini
[mysqld]
basedir=c:/dbs/5.1/
datadir=c:/dbs/5.1/data
port=3510
ignore-builtin-innodb
plugin-load=innodb=ha_innodb_plugin.dll
plugin-load=example=ha_example.dll
log-bin = mydb

Start the server:

c:\dbs>c:\dbs\5.1\bin\mysqld --defaults-file=c:\dbs\5.1\my.ini --standalone --console
091111 15:14:07 [Note] Plugin 'FEDERATED' is disabled.
091111 15:14:08 [Note] Event Scheduler: Loaded 0 events
091111 15:14:08 [Note] c:\dbs\5.1\bin\mysqld: ready for connections.
Version: '5.1.42-Win X64-log'  socket: ''  port: 3510  Source distribution

Notice the InnoDB plugin isn't loaded.

c:\dbs>5.1\bin\mysql -uroot --port=3510 --e="show engines;"
+------------+---------+------------------------------------
| Engine     | Support | Comment
+------------+---------+------------------------------------
| EXAMPLE    | YES     | Example storage engine
| CSV        | YES     | CSV storage engine
| MRG_MYISAM | YES     | Collection of identical MyISAM tabl
| BLACKHOLE  | YES     | /dev/null storage engine (anything
| FEDERATED  | NO      | Federated MySQL storage engine
| MyISAM     | DEFAULT | Default engine as of MySQL 3.23 wit
| ARCHIVE    | YES     | Archive storage engine
| MEMORY     | YES     | Hash based, stored in memory, usefu
+------------+---------+------------------------------------

You have now Example engine but not InnoDB engine.

How to repeat:
See description.

Suggested fix:
-
[11 Nov 2009 20:47] Calvin Sun
This is not a bug. The manual states:

"All plugins to load must be named in the same --plugin-load option. If multiple --plugin-load options are given, only the last one is used.", from http://dev.mysql.com/doc/refman/5.1/en/server-options.html.

Thanks,
Calvin