问题描述:在数据库上运行xtrabackup备份脚本出现的一些报错

DB_version:mysql8.0.26

Xtrabackup:percona-xtrabackup-8.0.27-19-Linux-x86_64.glibc2.12.tar.gz

[root@orch2 scripts]# $xtrDir --defaults-file=$mysql_cnf --user=$mysql_user --password=$mysql_password --socket=$mysql_socket --compress --compress-threads=2 --backup --target-dir=$target_dir
xtrabackup: recognized server arguments: --datadir=/home/mysql/db_orch2/data --tmpdir=/home/mysql/db_orch2/tmp --log_bin=/home/mysql/db_orch2/binlog/orch2-bin --log-bin-index=/home/mysql/db_orch2/binlog/orch2-bin.index --server-id=1330611 --innodb_open_files=63000 --innodb_data_home_dir=/home/mysql/db_orch2/data --innodb_log_group_home_dir=/home/mysql/db_orch2/data --innodb_log_file_size=8G --innodb_log_files_in_group=4 --innodb_undo_directory=/home/mysql/db_orch2/ulog --innodb_undo_tablespaces=3 --innodb_flush_log_at_trx_commit=2 --innodb_flush_method=O_DIRECT --innodb_io_capacity=3000 --innodb_buffer_pool_size=64G --innodb_log_buffer_size=32M --innodb_max_dirty_pages_pct=85 --innodb_adaptive_hash_index=1 --innodb_data_file_path=ibdata1:512M:autoextend --innodb_write_io_threads=16 --innodb_read_io_threads=16
xtrabackup: recognized client arguments: --user=root --password=* --socket=/home/mysql/db_orch2/mysql.sock --compress --compress-threads=2 --backup=1 --target-dir=/home/mysql/backup/13306//2022-04-06
/root/percona-xtrabackup/bin/xtrabackup version 8.0.27-19 based on MySQL server 8.0.27 Linux (x86_64) (revision id: 50dbc8dadda)
Can't locate Data/Dumper.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 749.
BEGIN failed--compilation aborted at - line 749.
220406 12:26:14 Connecting to MySQL server host: localhost, user: root, password: set, port: not set, socket: /home/mysql/db_orch2/mysql.sock
Using server version 8.0.26
220406 12:26:14 Executing LOCK INSTANCE FOR BACKUP...
xtrabackup: uses posix_fadvise().
xtrabackup: cd to /home/mysql/db_orch2/data
xtrabackup: open files limit requested 0, set to 1024
xtrabackup: using the following InnoDB configuration:
xtrabackup: innodb_data_home_dir = /home/mysql/db_orch2/data
xtrabackup: innodb_data_file_path = ibdata1:512M:autoextend
xtrabackup: innodb_log_group_home_dir = /home/mysql/db_orch2/data
xtrabackup: innodb_log_files_in_group = 4
xtrabackup: innodb_log_file_size = 8589934592
xtrabackup: using O_DIRECT
Number of pools: 1
xtrabackup: inititialize_service_handles suceeded
220406 12:26:14 Connecting to MySQL server host: localhost, user: root, password: set, port: not set, socket: /home/mysql/db_orch2/mysql.sock
xtrabackup: Redo Log Archiving is not set up.
Starting to parse redo log at lsn = 1276785485862
220406 12:26:14 >> log scanned up to (1276786464962)
xtrabackup: Generating a list of tablespaces
xtrabackup: Generating a list of tablespaces
Scanning './'
Scanning '/home/mysql/db_orch2/ulog/'
Completed space ID check of 2 files.
Allocated tablespace ID 2198 for eomaqzy_data/app_source_rela, old maximum was 0
220406 12:26:15 >> log scanned up to (1276786574060)
Undo tablespace number 1 was being truncated when mysqld quit.
Cannot recover a truncated undo tablespace in read-only mode
xtrabackup: error: xb_load_tablespaces() failed with error code 57

查看数据文件目录下是否有undo文件,清理undo文件重新测试备份

mv undo*.log /tmp

报错二:

xtrabackup: Can't create/write to file '/home/mysql/backup/13306/2022-04-06/eomaqzy_data/pl02_inv_meter_data.ibd.qp' (OS errno 24 - Too many open files)
您在 /var/spool/mail/root 中有邮件

操作系统文件数未调整限制

[root@orch2 13306]# ulimit -n
1024 [root@orch2 ~]# grep -i nofile /etc/security/limits.conf
# - nofile - max number of open file descriptors [root@orch2 ~]# vim /etc/security/limits.conf
* hard nofile 65535
* soft nofile 65535 断开链接,重新登录
[root@orch2 ~]# ulimit -n
65535

重新备份

+ echo =========================Run full backup beginning==========================
+ /root/percona-xtrabackup/bin/xtrabackup --defaults-file=/home/mysql/db_orch2/conf/orch2.cnf --user=root --password=XXXXX --socket=/home/mysql/db_orch2/mysql.sock --compress --compress-threads=2 --backup --target-dir=/home/mysql/backup/13306/2022-04-06
+ echo =========================Run full backup finished successfully==========================
您在 /var/spool/mail/root 中有邮件

xtrabackup: error: xb_load_tablespaces() failed with error code 57的更多相关文章

  1. Oracle Error - "OCIEnvCreate failed with return code -1 but error message text was not available".

    ISSUE: When trying to connect to an Oracle database you receive the following error: "OCIEnvCre ...

  2. axios请求报Uncaught (in promise) Error: Request failed with status code 404

    使用axios处理请求时,出现的问题解决 当url是远程接口链接时,会报404的错误: Uncaught (in promise) Error: Request failed with status ...

  3. ionic cordova build android error: commamd failed with exit code eacces

    问题: 电脑的gradle版本为Gradle 5.0,然而 因为 添加的android 平台为6.3.0 gradle 是 4.1版本 电脑已存在 gradle的情况下,add platform 成功 ...

  4. Qt error ------ 出现Error - RtlWerpReportException failed with status code :-1073741823. Will try to launch the process directly

    出现原因: 使用了不存在的对象 数组越界了 用 delete 释放未分配的内存空间,或者超过一次释放同个内存 比如: 顺序不能颠倒 正确: ui->setupUi(this); ui->t ...

  5. Uncaught (in promise) Error: Request failed with status code 500解决方案

    今天又学到一种修改bug的方法  : let newpwd = crypto.createHash('md5').update(req.body.upwd).digest('hex'); 在点击按钮加 ...

  6. rsync @ERROR: auth failed on module backup 解决思路及附录rsync常见问题及解决办法

    昨晚小版本上线,使用rsync往服务器上传文件时,client报如下异常: @ERROR: auth failed on module backup rsync error: error starti ...

  7. ZZW原创_rsync同步时由于注释问题引起的@ERROR: chdir failed

    1.需求:A机器同步文件到B机器 2.问题: A机器执行如下命令: [root@sv0379 rsync]# rsync -vzrtopg  --password-file=/usr/local/rs ...

  8. git clone的时候报error: RPC failed; result=18错误

    因业务需求,需要把内网gitlab仓库的地址对外网访问,在gitlab前端配置了一个nginx代理服务器,来实现需求,可以在git clone的时候报error: RPC failed错误 [root ...

  9. srync:@ERROR: auth failed on module tee 的解决办法分析

    首先:检查server端和client端的用户名和密码确认都无误: 然后:检查了服务器端/etc/rsyncd.conf 配置文件未发现异常, 再次:通过配置文件找到了log存放目录 $ cat /e ...

  10. RSYNC @ERROR: AUTH FAILED ON MODULE XXX 解决思路及附录RSYNC常见问题及解决办法

    使用rsync往服务器上传文件时,client报如下异常: @ERROR: auth failed on module XXX rsync error: error starting client-s ...

随机推荐

  1. .NetCore中配置Ef

    1.在NuGet中下载 Microsoft.EntityFrameworkCore.Tools Microsoft.EntityFrameworkCore.SqlServer 2.需要在Api层.实现 ...

  2. Maven-高级

    Mvaen 高级 1 导入其他工程 资源文件 先install到仓库里 然后根据组织名项目名版本号写在dependence里正常导入 <dependence> <groupId> ...

  3. 实验八-Web部署

    进入华为云中购置的虚拟机 配置openEuler cd /etc/yum.repos.d vi openEuler_x86_64.repo 安装LAMP 在shell中 通过下面命令安装Apache: ...

  4. Spyglass CDC工具使用(三)

    最近一直在搞CDC (clock domain crossing) 方面的事情,现在就CDC的一些知识点进行总结. 做CDC检查使用的是Spyglass工具.以下内容转载自:Spyglass之CDC检 ...

  5. awk sub string

    cat TFY1C.txt|awk '{print $0"\t"substr($4,1,4)}'> TFY1CRID.tx 1--从那位开始 4--多长

  6. HTML笔记(二) HTML标签元素

    一 常用的头部元素标签 <head>元素包含了所有的头部标签元素. 1.<title> <title>标签定义了HTML文档的标题,在HTML/XHTML文档中是必 ...

  7. kettle连接oracle

    连接oracle 10g 驱动classes12.jar 配置一下三项即可: 1.数据库名称:ip:端口/实例 2.用户名 3.密码

  8. Linux值得收藏的40个命令总结,常用的正则表达式

    1 删除0字节文件 find -type f -size 0 -exec rm -rf {} \; 2 查看进程 按内存从大到小排列 PS -e -o "%C : %p : %z : %a& ...

  9. something to SSSSay

    可能记录写博客的初衷,现在的状态,一些目标.想法. 首先让我拟定几个关键词: 半吊子程序员 咸鱼 欲求不满 终生学习 自律 <差不多程序员> 长得差不多(175)高,看着差不多(普通)帅, ...

  10. LoadRunner——分析图详解(十四)

    <分析图详解> 一.Running V user s 图 X轴表示运行所用的时间,Y轴表示vuser数, 显示在整个运行过程中随着时间的推移,虚拟用户数量是如何变化的,具体描述为:用户是如 ...