MySQL 5.6.14 Source Code Document
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
shutdown_mysqld.inc
1 # This is the first half of include/restart_mysqld.inc.
2 if ($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 it
11 --let $_server_id= `SELECT @@server_id`
12 --let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$_server_id.expect
13 --exec echo "wait" > $_expect_file_name
14 
15 # Send shutdown to the connected server
16 --shutdown_server
17 --source include/wait_until_disconnected.inc
18