1
2if ($rpl_inited)
3{
4  if (!$allow_rpl_inited)
5  {
6    --die ERROR IN TEST: When using the replication test framework (master-slave.inc, rpl_init.inc etc), use rpl_restart_server.inc instead of restart_mysqld.inc. If you know what you are doing and you really have to use restart_mysqld.inc, set allow_rpl_inited=1 before you source restart_mysqld.inc
7  }
8}
9
10# Write file to make mysql-test-run.pl expect the "crash", but don't start
11# it until it's told to
12--let $_server_id= `SELECT @@server_id`
13--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$_server_id.expect
14
15# MCP -->
16# patch to allow restarting different server than the one currently
17# connected to, actually one where suffix is not .serverid but
18# .serverid.clusterid
19if (`SELECT LENGTH("$mysqld_name")`)
20{
21  let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/$mysqld_name.expect;
22  # echo expect_file_name: $_expect_file_name;
23}
24# MCP <--
25--exec echo "wait" > $_expect_file_name
26
27# Send shutdown to the connected server and give
28# it 10 seconds to die before zapping it
29shutdown_server 10;
30
31--source include/wait_until_disconnected.inc
32