Skip to content

Commit f88d130

Browse files
MDEV-24248: my_print_defaults is not taking all the values when using -e
option which is called from mysql.server (extra_args). Fix: change mysql.server script to use --defaults-extra-file instead of -e
1 parent 3529405 commit f88d130

File tree

3 files changed

+49
-2
lines changed

3 files changed

+49
-2
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#
2+
# Beginning of 10.5 Test
3+
#
4+
#
5+
# MDEV-24248: my_print_defaults is not taking all the values when using
6+
# -e option which is called from mysql.server (extra_args).
7+
#
8+
# checking for mysql.server
9+
--key_buffer_size=20M
10+
--max_allowed_packet=250M
11+
--table_open_cache=1000
12+
--table_definition_cache=2000
13+
--read_buffer_size=1M
14+
--thread_cache_size=8
15+
--max_connections=1024
16+
--long_query_time=60
17+
--slow_query_log=1
18+
# End of 10.5 test
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
--echo #
2+
--echo # Beginning of 10.5 Test
3+
--echo #
4+
--echo #
5+
--echo # MDEV-24248: my_print_defaults is not taking all the values when using
6+
--echo # -e option which is called from mysql.server (extra_args).
7+
--echo #
8+
9+
--echo # checking for mysql.server
10+
11+
--write_file $MYSQLTEST_VARDIR/tmp/tmp1.cnf
12+
13+
[mariadb]
14+
key_buffer_size=20M
15+
max_allowed_packet=250M
16+
table_open_cache=1000
17+
table_definition_cache=2000
18+
read_buffer_size=1M
19+
thread_cache_size=8
20+
max_connections=1024
21+
long_query_time=60
22+
slow_query_log=1
23+
EOF
24+
25+
--exec $MYSQL_MY_PRINT_DEFAULTS --defaults-extra-file=$MYSQLTEST_VARDIR/tmp/tmp1.cnf --mysqld mysql.server
26+
27+
--remove_file $MYSQLTEST_VARDIR/tmp/tmp1.cnf
28+
29+
--echo # End of 10.5 test

support-files/mysql.server.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -200,11 +200,11 @@ su_kill() {
200200
extra_args=""
201201
if test -r "$basedir/my.cnf"
202202
then
203-
extra_args="-e $basedir/my.cnf"
203+
extra_args="--defaults-extra-file=$basedir/my.cnf"
204204
else
205205
if test -r "$datadir/my.cnf"
206206
then
207-
extra_args="-e $datadir/my.cnf"
207+
extra_args="--defaults-extra-file=$datadir/my.cnf"
208208
fi
209209
fi
210210

0 commit comments

Comments
 (0)