Skip to content

Commit 641c1a8

Browse files
WL#7895 - Add systemd support to server.
Post push fix - Add include/have_mysqld_safe.inc
1 parent 603fb23 commit 641c1a8

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed
+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#################################################
2+
# Checks if mysqld_safe is installed in the path
3+
# specified by MTR. mysqld_safe is obsolete on
4+
# platforms that use systemd to monitor mysqld.
5+
#################################################
6+
7+
--disable_query_log
8+
--let $temp_inc=$MYSQL_TMP_DIR/tmp.inc
9+
let inc_tmp=$temp_inc;
10+
11+
--perl
12+
use strict;
13+
my $is_mysqld_safe_present=0;
14+
$is_mysqld_safe_present=1 if -e $ENV{'MYSQLD_SAFE'};
15+
16+
my $temp_inc= $ENV{'inc_tmp'} or die "temp_inc not set";
17+
open(FILE_INC, ">", "$temp_inc") or die("can't open file \"$temp_inc\": $!");
18+
print FILE_INC '--let $is_found= '.$is_mysqld_safe_present;
19+
20+
EOF
21+
22+
--source $temp_inc
23+
24+
if (!$is_found)
25+
{
26+
--skip Tests using mysqld_safe skipped.
27+
}
28+
29+
--remove_file $temp_inc
30+
--enable_query_log

0 commit comments

Comments
 (0)