diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-1.png" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-1.png" new file mode 100755 index 0000000000000000000000000000000000000000..f173216dd29751059dc73f972c6c8dc527432b66 Binary files /dev/null and "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-1.png" differ diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-2.png" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-2.png" new file mode 100755 index 0000000000000000000000000000000000000000..b46ba9e3669945f7e6e7860f159542f212819b42 Binary files /dev/null and "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-2.png" differ diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-3.png" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-3.png" new file mode 100755 index 0000000000000000000000000000000000000000..0ab327aa4d833abfcfbb8a9d3babec913e23651a Binary files /dev/null and "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-3.png" differ diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-4.png" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-4.png" new file mode 100755 index 0000000000000000000000000000000000000000..282e2a069ae1a1865e24819ad64e9b20a2b32bf7 Binary files /dev/null and "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-4.png" differ diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-5.png" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-5.png" new file mode 100755 index 0000000000000000000000000000000000000000..b4edf223930cef1620e00f23517a907318bcf1a4 Binary files /dev/null and "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-5.png" differ diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-6.png" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-6.png" new file mode 100755 index 0000000000000000000000000000000000000000..5a1ec6411c19e39c5a5665de217e59bd1c208562 Binary files /dev/null and "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image-6.png" differ diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image.png" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image.png" new file mode 100755 index 0000000000000000000000000000000000000000..a5c309867ab22ce29149622bb42565fa431df413 Binary files /dev/null and "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/image.png" differ diff --git "a/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212.md" "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212.md" new file mode 100755 index 0000000000000000000000000000000000000000..98ae01b42f590fa9761d39e60bb0619ed4e9e1ff --- /dev/null +++ "b/Test_Result/openGauss_6.0.0_release/\345\206\205\346\240\270\345\234\272\346\231\257\345\214\226/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212/openGauss 6.0.0\347\211\210\346\234\254walwriteraux\347\272\277\347\250\213\346\224\257\346\214\201\351\242\204\345\210\206\351\205\215XLog\346\226\207\344\273\266\346\265\213\350\257\225\346\212\245\345\221\212.md" @@ -0,0 +1,132 @@ +![avatar](../images/openGauss.png) + +版权所有 © 2024 openGauss社区 +您对“本文档”的复制、使用、修改及分发受知识共享(Creative Commons)署名—相同方式共享4.0国际公共许可协议(以下简称“CC BY-SA 4.0”)的约束。为了方便用户理解,您可以通过访问https://creativecommons.org/licenses/by-sa/4.0/ 了解CC BY-SA 4.0的概要 (但不是替代)。CC BY-SA 4.0的完整协议内容您可以访问如下网址获取:https://creativecommons.org/licenses/by-sa/4.0/legalcode。 + +修订记录 + +| 日期 | 修订 版本 | 修改描述 | 作者 | +| ---- | ----------- | -------- | ---- | +| 2024.07.26 | 1.0 | openGauss 6.0.0版本walwriteraux线程支持预分配XLog文件测试报告初稿完成 | munan | +| 2024.07.30 | 2.0 | 补充说明遗留问题 |munan | +| | | | | + + 关键词: 预分配、xlog、性能 + + + +摘要: +本文对openGauss 6.0.0版本walwriteraux线程支持预分配XLog文件特性测试情况进行详细说明,并给出最终测试结论。 + + +缩略语清单: + +| 缩略语 | 英文全名 | 中文解释 | +| ------ | -------- | -------- | +| | | | +| | | | + +# 1 特性概述 + +本特性从6.0.0版本开始支持在WalWriter线程刷wal日志到磁盘的时候,当剩余可用xlog文件低于g_instance.attr.attr_storage.wal_file_init_num * 0.2时,即触发WALwriteraux线程预分配xlog文件的流程,从而保证后续walwriter线程在事务提交刷日志时,不会遇到无xlog文件可用的情形。 + +# 2 特性测试信息 + +本节描述被测对象的版本信息和测试的时间及测试轮次,包括依赖的硬件。 + +| 版本名称 | 测试起始时间 | 测试结束时间 | +| -------- | ------------ | ------------ | +| openGauss 6.0.0 B023 ,openGauss 6.0.0 B022 | 2024-07-18 | 2024-07-25 | +| openGauss 6.0.0 B025 | 2024-08-01 | 2024-08-08 | + + +描述特性测试的硬件环境信息 + +| 环境信息 | 配置信息 | 备注 | +| -------- | -------- | ---- | +| 机架式PC服务器 | CPU: Intel(R) Xeon(R) Gold 5218 CPU @ 2.30GHz, 内存:384GB, 操作系统: openEuler 20.03 (LTS-SP1),内核:Linux 4.19.90-2109.1.0.0108.oe1.x86_64 | | + +# 3 测试结论概述 + +## 3.1 测试整体结论 + +支持根据阈值预分配xlog文件共计执行14个用例,主要覆盖功能测试、可靠性测试和性能测试,通过手工执行用例,发现问题1个,已修复待验证,无遗留风险,整体质量良好。 + +| 测试活动 | 测试结果 | +| -------- | -------- | +| 用例一:数据库默认设置,wal_file_init_num = 10(default),archive_mode = on,archive_command = 'cp --remove-destination %p /home/aa/bb/cc/dd/%f',验证剩余可用xlog文件数满足阈值条件时,会进行预分配 | 不计当前切换到的xlog文件,当剩余可用xlog文件数等于wal_file_init_num*0.2,会新建 wal_file_init_num个xlog文件 ![alt text](image-1.png) | +| 用例二:与6.0.0B022版本比对,wal_file_init_num = 10(default),archive_mode = on,archive_command = 'cp --remove-destination %p /home/aa/bb/cc/dd/%f',验证新功能会提前进行预分配 | B022版本当无可用xlog文件时才会创建新xlog文件,B023版本支持提前创建 | +|用例三:设置 alter system set wal_file_init_num to 20; | 预分配成功,提前4个创建 | +|用例四:改变参数设置,synchronous_commit = off (default: on) | 预分配成功 | +| 用例五:改变参数设置,synchronous_commit = local (default: on) | 预分配成功 | +| 用例六:改变参数设置,wal_level = logical (default: hot_standby) | 预分配成功 | +|用例七:改变参数设置,wal_level = archive (default: hot_standby),要求hot_standby = off | 预分配成功 | +|用例八:改变参数设置,wal_level = minimal (default: hot_standby),要求archive_mode = off, hot_standby = off, max_wal_senders = 0 | 预分配成功 | +|用例九:xlog故障,剩余可用xlog文件被删 | 发现一个缺陷:在所有空闲xlog文件都被删除情况下,当触发新文件预分配时,会从原来最大的空闲xlog文件号处增加新文件,导致手工删除的这些文件编号依然空缺 | +|用例十:xlog故障,可用xlog被误改权限 | 数据库崩溃报错, ![alt text](image.png) | +|用例十一:执行select pg_switch_xlog() |预分配成功 +|用例十二:一主一备跑tpcc,验证对现有功能是否有影响 |符合一致性![alt text](image-4.png) +|用例十三:分别在B022和B023(合入版本)进行tpcc测试,设置500仓、200并发,incremental_checkpoint_timeout = 1800s,比对结果 |B022:tpmC = 238190.38![alt text](image-2.png) B023:tpmC = 254480.54![alt text](image-3.png) +|用例十四:分别在B022和B023(合入版本)进行tpcc测试,设置1000仓、500并发, incremental_checkpoint_timeout = 300s,比对结果 |B022:tpmC = 233080.35![alt text](image-6.png)B023:tpmC = 271446.05![alt text](image-5.png) + + + +## 3.2 约束说明 + +无 + +## 3.3 遗留问题分析 + +### 3.3.1 遗留问题影响以及规避措施 + +| 问题单号 | 问题描述 | 问题级别 | 修复PR | 当前状态 | +| -------- | -------- | -------- | ------------------ | -------- | +| #IAE3L1 | 删除可用xlog文件情况下进行预分配有问题https://gitee.com/opengauss/openGauss-server/issues/IAE3L1?from=project-issue | 次要 | 5837 | 在B025版本已验证 | + + + + +### 3.3.2 问题统计 + +| | 问题总数 | 严重 | 主要 | 次要 | 不重要 | +| ------ | -------- | ---- | ---- | ---- | ------ | +| 数目 | 1 | 0 | 0 | 1 | 0 | +| 百分比 | 100% | 0 | 0 | 100% | 0 | + +# 4 测试执行 + +## 4.1 测试执行统计数据 + +*本节内容根据测试用例及实际执行情况进行特性整体测试的统计,可根据第二章的测试轮次分开进行统计说明。* + +| 版本名称 | 测试用例数 | 发现问题单数 | +| -------- | ---------- | ------------ | +|openGauss 6.0.0 B023 | 14 | 1 | + + +*数据项说明:* + +测试用例执行14个,通过13个。 + +本需求发现缺陷1个。 + +## 4.2 后续测试建议 + + + 1. 确认一下开发代码量:10+行 + 2. wal_file_init_num =0时,不预分配 + 3. 确认wal_file_init_num和2*checkpoint_segments+1的关系,无关系 + 4. 主备switch over:主正常预分配,进行switchover主备交换角色,再进行switchover主备恢复角色,主机都能预分配成功 + 5. 主备fail over:备机升主能够成功预分配,主机再加入恢复主备模式,主机依然能够成功预分配 + +# 5 附件 + +*此处可粘贴各类专项测试数据或报告* + + + + + + + +