ICode9

精准搜索请尝试: 精确搜索
首页 > 数据库> 文章详细

【mysql MTR】MTR's internal check of the test case 'xxx' failed的解决方法

2022-09-14 14:32:40  阅读:232  来源: 互联网

标签:case ... extern MTR xxx -- mysql test dropdb


(1)报错信息如下

[root@dev mysql-test]# ./mtr --suite=tianmu dropdb.test --force
Logging: ./mtr  --suite=tianmu dropdb.test --force
MySQL Version 5.7.36
Checking supported features...
 - SSL connections supported
Collecting tests...
Checking leftover processes...
Removing old var directory...
Creating var directory '/data/stonedb57/install/mysql-test/var'...
Installing system database...
Using parallel: 1
==============================================================================
TEST                                      RESULT   TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 13000..13009
worker[1] mysql-test-run: WARNING: running this script as _root_ will cause some tests to be skipped
[ 50%] tianmu.dropdb                            [ pass ]     16
#############报错信息如下###############
MTR's internal check of the test case 'tianmu.dropdb' failed.
This means that the test case does not preserve the state that existed
before the test case was executed.  Most likely the test case did not
do a proper clean-up. It could also be caused by the previous test run
by this thread, if the server wasn't restarted.
This is the diff of the states of the servers before and after the
test case was executed:
mysqltest: Logging to '/data/stonedb57/install/mysql-test/var/tmp/check-mysqld_1.log'.
mysqltest: Results saved in '/data/stonedb57/install/mysql-test/var/tmp/check-mysqld_1.result'.
mysqltest: Connecting to server localhost:13000 (socket /data/stonedb57/install/mysql-test/var/tmp/mysqld.1.sock) as 'root', connection 'default', attempt 0 ...
mysqltest: ... Connected.
mysqltest: Start processing test commands from './include/check-testcase.test' ...
mysqltest: ... Done processing test commands.
Binary files /data/stonedb57/install/mysql-test/var/tmp/check-mysqld_1.result and /data/stonedb57/install/mysql-test/var/tmp/check-mysqld_1.reject differ
mysqltest: Result content mismatch

not ok
safe_process[31443]: Child process: 31444, exit: 1
[100%] shutdown_report                          [ pass ]       
--------------------------------------------------------------------------
The servers were restarted 0 times
Spent 0.016 of 19 seconds executing testcases
Check of testcase failed for: tianmu.dropdb
Completed: All 2 tests were successful.

(2)问题分析

根据自己的判定,这些内容应全部执行成功,但是在运行的时候出现了如上的报错,经过分析得出结果:

一般情况下mtr是启动自己的MySQL服务来进行测试,如果在启动时指定参数—extern,则可以使用指定的MySQL服务进行测试;

(3)解决方法

在运行的脚本中添加上自己数据库的服务器相关信息,即可看到运行成功

./mtr --extern host=192.168.30.45 --extern port=3306 --extern user=root --extern password="123456" --suite=tianmu --force dropdb.test

得出结果如下,可看到问题已被解决

Logging: ./mtr  --extern host=192.168.30.45 --extern port=3306 --extern user=root --extern password=123456 --suite=tianmu --force dropdb.test
mysql: [Warning] Using a password on the command line interface can be insecure.
MySQL Version 5.7.36
Checking supported features...
 - SSL connections supported
Collecting tests...
Using parallel: 1

==============================================================================

TEST                                      RESULT   TIME (ms) or COMMENT
--------------------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 13000..13009
worker[1] mysql-test-run: WARNING: running this script as _root_ will cause some tests to be skipped
[ 50%] tianmu.dropdb                            [ pass ]     17
[100%] shutdown_report                          [ pass ]       
--------------------------------------------------------------------------
The servers were restarted 0 times
Spent 0.017 of 1 seconds executing testcases

Completed: All 2 tests were successful.

 

标签:case,...,extern,MTR,xxx,--,mysql,test,dropdb
来源: https://www.cnblogs.com/syw20170419/p/16692918.html

本站声明: 1. iCode9 技术分享网(下文简称本站)提供的所有内容,仅供技术学习、探讨和分享;
2. 关于本站的所有留言、评论、转载及引用,纯属内容发起人的个人观点,与本站观点和立场无关;
3. 关于本站的所有言论和文字,纯属内容发起人的个人观点,与本站观点和立场无关;
4. 本站文章均是网友提供,不完全保证技术分享内容的完整性、准确性、时效性、风险性和版权归属;如您发现该文章侵犯了您的权益,可联系我们第一时间进行删除;
5. 本站为非盈利性的个人网站,所有内容不会用来进行牟利,也不会利用任何形式的广告来间接获益,纯粹是为了广大技术爱好者提供技术内容和技术思想的分享性交流网站。

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有