[MDEV-22349] MTR re-bootstrap modifies environment variable MYSQLD_BOOTSTRAP_CMD Created: 2020-04-23  Updated: 2020-04-23  Resolved: 2020-04-23

Status: Closed
Project: MariaDB Server
Component/s: Tests
Affects Version/s: 10.1, 10.2, 10.3, 10.4, 10.5
Fix Version/s: 10.1.45, 10.2.32, 10.3.23, 10.4.13, 10.5.3

Type: Bug Priority: Major
Reporter: Elena Stepanova Assignee: Elena Stepanova
Resolution: Fixed Votes: 0
Labels: None


 Description   

For tests with options not compatible with the default bootstrapped datadir, MTR performs local rebootstrap, without touching the clean install.db.

While doing so, MTR modifies MYSQLD_BOOTSTRAP_CMD environment variable. It shouldn't be happening, the variable should remain the same as it was initially, to avoid dependency on the sequence of tests. If a test uses the variable and needs it to be modified, it should be done explicitly in the test itself.

--- /data/src/10.4/mysql-test/mysql-test-run.pl	2020-04-23 01:23:11.583215104 +0300
+++ mysql-test-run.pl	2020-04-23 04:31:16.384303120 +0300
@@ -3369,7 +3369,8 @@
   # ----------------------------------------------------------------------
   # export MYSQLD_BOOTSTRAP_CMD variable containing <path>/mysqld <args>
   # ----------------------------------------------------------------------
-  $ENV{'MYSQLD_BOOTSTRAP_CMD'}= "$exe_mysqld_bootstrap " . join(" ", @$args);
+  $ENV{'MYSQLD_BOOTSTRAP_CMD'}= "$exe_mysqld_bootstrap " . join(" ", @$args)
+    unless defined $ENV{'MYSQLD_BOOTSTRAP_CMD'};
 
   # Extra options can come not only from the command line, but also
   # from option files or combinations. We want them on a command line


Generated at Thu Feb 08 09:14:03 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.