Xtrabackup 2.1.1 failing with Percona-Server 5.1

I noticed error messages popping up this morning with a dr replication script I have been writing after xtrabackup updated last night. I am seeing the following errors in the logs:

innobackupex: Error: Support for MySQL 5.1 with builtin InnoDB (not the plugin) was removed in Percona XtraBackup 2.1. The last version to support MySQL 5.1 with builtin InnoDB was Percona XtraBackup 2.0. at /usr/bin/innobackupex line 387.

I am not sure what I am missing, but I am using Percona 5.1 not vanilla MySQL.

I do see that the built in innodb engine is being listed in the information_schema which is a bit strange:

±------------±---------------±--------------------±---------------±-----------------------±--------------+
| PLUGIN_NAME | PLUGIN_VERSION | PLUGIN_TYPE_VERSION | PLUGIN_LIBRARY | PLUGIN_LIBRARY_VERSION | PLUGIN_AUTHOR |
±------------±---------------±--------------------±---------------±-----------------------±--------------+
| InnoDB | 5.1 | 50168.0 | NULL | NULL | Innobase Oy |
±------------±---------------±--------------------±---------------±-----------------------±--------------+

| innodb_version | 5.1.68-14.6 |

Percona-Server-client-51.x86_64 5.1.68-rel14.6.551.rhel6 @percona
Percona-Server-server-51.x86_64 5.1.68-rel14.6.551.rhel6 @percona
Percona-Server-shared-51.x86_64 5.1.68-rel14.6.551.rhel6 @percona
percona-xtrabackup.x86_64 2.1.1-600.rhel6 @percona

Also my my.cnf file is mainly empty, there are a few things for replication. The only innodb specific setting is file per table.

So does Xtrabackup 2.1.1 no longer support Percona 5.1 or am I just missing something obvious?

This looks like the code in question:


	 if($var_version =~ m/5\.1\.\d/ && $var_innodb_version =~ m/.*/) {
	 Die "Support for MySQL 5.1 with builtin InnoDB (not the plugin) was removed in Percona XtraBackup 2.1. The last version to support MySQL 5.1 with builtin InnoDB was Percona XtraBackup 2.0.";
	 }
	
Basically, if MySQL matches 5.1 and innodb_version matches anything, die.

Interestingly enough there is more code below that works with 5.1 and innodb_version 1.0.x:

	 if($var_version =~ m/5\.1\.\d/ && $var_innodb_version =~ m/1\.0\.\d+$/) {
	 $ibbackup_binary = ($win eq 1 ? 'xtrabackup.exe' : 'xtrabackup');
	 }
	

I’ve found the same issue with my server. From the error it sounds like the plugin should be allowed still. I’ve written the following patch that modifies the code you have above and makes it work. Can someone at Percona jump in on this thread and let me know if my assumptions are right or wrong. Thanks.

Patch:
[url]http://mos.greenaspen.com/misc/innobackupex.patch[/url]

Hi,

Please, upgrade to 2.1.2. We have fixed some bugs related with InnoDB plugin detection in 5.1:

[url]https://bugs.launchpad.net/percona-xtrabackup/+bug/1181092[/url]
[url]https://bugs.launchpad.net/percona-xtrabackup/+bug/1181099[/url]
[url]https://bugs.launchpad.net/percona-xtrabackup/+bug/1180905[/url]

Test it again with the new version and tell me if the problem is not solved.

Regards.

I’ve got the same problem with MySQL 5.1 and xtrabackup 2.1.2 on Debian 6

Server version: 5.1.66-0+squeeze1-log (Debian)
Xtrabackup: 2.1.2-611.squeeze
Debian GNU/Linux 6.0.7 (squeeze)



	mysql> select * from PLUGINS where PLUGIN_NAME = 'InnoDB' \G


	*************************** 1. row ***************************


	 PLUGIN_NAME: InnoDB


	 PLUGIN_VERSION: 1.0


	 PLUGIN_STATUS: ACTIVE


	 PLUGIN_TYPE: STORAGE ENGINE


	 PLUGIN_TYPE_VERSION: 50166.0


	 PLUGIN_LIBRARY: NULL


	PLUGIN_LIBRARY_VERSION: NULL


	 PLUGIN_AUTHOR: Innobase OY


	 PLUGIN_DESCRIPTION: Supports transactions, row-level locking, and foreign keys


	 PLUGIN_LICENSE: GPL


	1 row in set (0.00 sec)


For those looking for a quick workaround, try using the following option to explicitly set the backend:

–ibbackup=xtrabackup