innobackupex-1.5.1: Too many command line arguments

[root@xxxxxxopt]# /usr/bin/innobackupex-1.5.1 –-apply-log /opt/back_data/ --defaults-file=/opt/mysql/product/mysql/etc/my.cnf


innobackupex-1.5.1: Too many command line arguments

还没有找到问题所在, 去官网 http://www.percona.com/doc/percona-xtrabackup/howtos/recipes_ibkx_local.html 看到如此例子:

$ innobackupex --use-memory=4G --apply-log /data/backups/2010-03-13_02-42-44/

我加了一个--use-memory=4G 参数 ,就OK了:

[root@xxxxxxopt]# innobackupex --use-memory=4G --apply-log /opt/back_data/ --defaults-file=/opt/mysql/product/mysql/etc/my.cnf

InnoDB Backup Utility v1.5.1-xtrabackup; Copyright 2003, 2009 Innobase Oy
and Percona Inc 2009-2012. All Rights Reserved.

This software is published under
the GNU GENERAL PUBLIC LICENSE Version 2, June 1991.

IMPORTANT: Please check that the apply-log run completes successfully.
At the end of a successful apply-log run innobackupex
prints "completed OK!".

130407 14:45:07 innobackupex: Starting ibbackup with command: xtrabackup --defaults-file="/opt/mysql/product/mysql/etc/my.cnf" --prepare --target-dir=/opt/back_data --use-memory=4G

....................................................... 省略N多吧!

[notice (again)]
If you use binary log and don't use any hack of group commit,
the binary log position seems to be:
InnoDB: Last MySQL binlog file position 0 55881164, file name /mysqldata/data/mysql-bin.004217

xtrabackup: starting shutdown with innodb_fast_shutdown = 1
130407 14:45:29 InnoDB: Starting shutdown...
130407 14:45:29 InnoDB: Shutdown completed; log sequence number 247276497420
130407 14:45:29 innobackupex: completed OK!

[root@xxxxx mysqldata]# innobackupex --copy-back /opt/back_data --defaults-file=/opt/mysql/product/mysql/etc/my.cnf

InnoDB Backup Utility v1.5.1-xtrabackup; Copyright 2003, 2009 Innobase Oy
and Percona Inc 2009-2012. All Rights Reserved.

This software is published under
the GNU GENERAL PUBLIC LICENSE Version 2, June 1991.

IMPORTANT: Please check that the copy-back run completes successfully.
At the end of a successful copy-back run innobackupex
prints "completed OK!".

Original InnoDB log directory is not empty! at /usr/bin/innobackupex line 568.

Original data directory is not empty! at /usr/local/xtrabackup/bin/innobackupex line 538. 经查官网,这是xtrabackup的一个BUG。
innobackupex did not check that MySQL datadir was empty before –copy-back was run. With this bug fix, innobackupex will now error out of the –copy-back operation if the destination is not empty, avoiding potential data loss or a strang combination of a restored backup and previous data. Bug Fixed: #737569 (Valentine Gostev)
[OK]:直接手动copy过来到data目录即可。


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值