Details
Description
--source include/restart_mysqld.inc results in a test failure in Spider suites, with no output from mysqltest. Putting the following MTR test case to storage/spider/mysql-test/spider/bugfix/t reproduces the bug.
--source include/restart_mysqld.inc |
This doesn't happen at least in the main suite and the include file is used elsewhere. So, I expect that the problem is Spider-specific.
The Spider hangs on the server startup on 10.4+ (MDEV-22979) and thus the failure is expected on 10.4+. However, even on 10.2, the test fails. This is possibly due to a different reason.
Attachments
Issue Links
- blocks
-
MDEV-30370 mariadbd hangs when running with --wsrep-recover and --plugin-load-add=ha_spider.so
-
- Closed
-
The real problem is that shutdown_mysqld.inc (and, likely, other .inc files too) use @@server_id while mtr uses group suffix. If .inc files would be using the correct file name, spider tests wouldn't need to specify the expect file manually.
I suggest the following fix instead
---let $_server_id= `SELECT @@server_id`
---let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$_server_id.expect
+--let $_expect_file_name= `select regexp_replace(@@tmpdir, '^.*/','')`
that seems to work correctly for your spider test case and for other test cases too.
Perhaps this should be done in all other include files that use $_expect_file_name ?
Note, after this change innodb/t/temporary_table.test will fail, because it changes tmpdir to /dev/null/nonexistent. Can be fixed with
---exec echo "restart: --tmpdir=/dev/null/nonexistent" > $_expect_file_name
(and also add_suppression() at the top of the file needs to be adjusted)