XtraBackup备份出现"Can't locate Digest/MD5.pm in @INC"
2017-02-23 13:34 潇湘隐者 阅读(7658) 评论(0) 编辑 收藏 举报
在CentOS 7上安装了Xtrabackup 2.4.5(innobackupex version 2.4.5 Linux (x86_64) (revision id: e41c0be)),然后做备份时遇到下面错误信息“Can't locate Digest/MD5.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at - line 693”。 具体错误提示信息如下:
170222 10:57:29 innobackupex: Starting the backup operation
IMPORTANT: Please check that the backup run completes successfully.
At the end of a successful backup run innobackupex
prints "completed OK!".
Can't locate Digest/MD5.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at - line 693.
BEGIN failed--compilation aborted at - line 693.
170222 10:57:29 Connecting to MySQL server host: 127.0.0.1, user: root, password: set, port: 3306, socket: (null)
Using server version 5.6.20-enterprise-commercial-advanced-log
/usr/bin/innobackupex version 2.4.5 based on MySQL server 5.7.13 Linux (x86_64) (revision id: e41c0be)
xtrabackup: uses posix_fadvise().
xtrabackup: cd to /var/lib/mysql/
xtrabackup: open files limit requested 0, set to 1024
xtrabackup: using the following InnoDB configuration:
xtrabackup: innodb_data_home_dir = .
xtrabackup: innodb_data_file_path = ibdata1:12M:autoextend
xtrabackup: innodb_log_group_home_dir = ./
xtrabackup: innodb_log_files_in_group = 2
xtrabackup: innodb_log_file_size = 50331648
出现这个错误是因为安装Xtrabackup 2.4.5时,没有安装 perl-Digest-MD5组件。Percona官方文档里面介绍了使用yum、apt等安装方式,没有详细介绍使用rpm安装方式。这个文档里并没有要求安装组件perl-Digest-MD5。而我只安装了下面一些组件。
[root@DB-Server ~]# yum install cmake gcc gcc-c++ libaio libaio-devel automake autoconf bzr \
bison libtool ncurses5-devel
[root@DB-Server ~]# yum -y install perl perl-devel perl-Time-HiRes perl-DBD-MySQL
安装了perl-Digest-MD5后,问题即可解决。
[root@DB-Server ~]# yum -y install perl-Digest-MD5
![](https://images.cnblogs.com/cnblogs_com/kerrycode/1913302/o_240731062102_kerrycode.png)
扫描上面二维码关注我
如果你真心觉得文章写得不错,而且对你有所帮助,那就不妨帮忙“推荐"一下,您的“推荐”和”打赏“将是我最大的写作动力!
本文版权归作者所有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接.