📄 im_life_cycle.imtest
字号:
############################################################################# This file contains test for (1.1) test suite.## Consult WL#2789 for more information.############################################################################--source include/im_check_os.inc############################################################################# 1.1.1. Check that Instance Manager is able:# - to read definitions of two mysqld-instances;# - to start the first instance;# - to understand 'nonguarded' option and keep the second instance down;############################################################################SHOW INSTANCES;--replace_column 3 VERSIONSHOW INSTANCE STATUS mysqld1;--replace_column 3 VERSIONSHOW INSTANCE STATUS mysqld2;############################################################################# 1.1.2. Check 'START INSTANCE' command:# - start the second instance;# - check that it is reported as online;# - execute some SQL-statement on mysqld2 to ensure that it is really up and# running;############################################################################START INSTANCE mysqld2;# FIXME--sleep 3SHOW INSTANCES;--replace_column 3 VERSIONSHOW INSTANCE STATUS mysqld1;--replace_column 3 VERSIONSHOW INSTANCE STATUS mysqld2;--connect (mysql_con,localhost,root,,mysql,$IM_MYSQLD1_PORT,$IM_MYSQLD1_SOCK)--connection mysql_con--replace_result $IM_MYSQLD1_PORT IM_MYSQLD1_PORTSHOW VARIABLES LIKE 'port';--connection default--disconnect mysql_con############################################################################# 1.1.3. Check 'STOP INSTANCE' command:# - stop the second instance;# - check that it is reported as offline;# - TODO: try to execute some SQL-statement to ensure that it is really down;############################################################################STOP INSTANCE mysqld2;# FIXME--sleep 3SHOW INSTANCES;--replace_column 3 VERSIONSHOW INSTANCE STATUS mysqld1;--replace_column 3 VERSIONSHOW INSTANCE STATUS mysqld2;############################################################################# 1.1.4. Check that Instance Manager reports correct errors for 'START# INSTANCE' command:# - if the client tries to start unregistered instance;# - if the client tries to start already started instance;# - if the client submits invalid arguments;############################################################################--error 3000START INSTANCE mysqld3;--error 3002START INSTANCE mysqld1;# FIXME TODO# BUG#12813: START/STOP INSTANCE commands accept a list as argument# START INSTANCE mysqld1, mysqld2;############################################################################# 1.1.5. Check that Instance Manager reports correct errors for 'STOP INSTANCE'# command:# - if the client tries to start unregistered instance;# - if the client tries to start already stopped instance;# - if the client submits invalid arguments;############################################################################--error 3000STOP INSTANCE mysqld3;# TODO: IM should be fixed.# BUG#12673: Instance Manager allows to stop the instance many times# --error 3002# STOP INSTANCE mysqld2;# FIXME TODO# BUG#12813: START/STOP INSTANCE commands accept a list as argument# STOP INSTANCE mysqld1, mysqld2;############################################################################# 1.1.6. Check that Instance Manager is able to restart guarded instances.############################################################################SHOW INSTANCES;--exec $MYSQL_TEST_DIR/t/kill_n_check.sh $IM_MYSQLD1_PATH_PID restarted############################################################################# 1.1.7. Check that Instance Manager does not restart non-guarded instance.############################################################################SHOW INSTANCES;START INSTANCE mysqld2;# FIXME--sleep 3SHOW INSTANCES;--exec $MYSQL_TEST_DIR/t/kill_n_check.sh $IM_MYSQLD2_PATH_PID killedSHOW INSTANCES;############################################################################# 1.1.8. Check that Instance Manager returns an error on# incomplete SHOW INSTANCE STATUS command.############################################################################--error 1149SHOW INSTANCE STATUS;## Tests for bug fixes### Bug #12813 Instance Manager: START/STOP INSTANCE commands accept# a list as argument.#--error 1149START INSTANCE mysqld1,mysqld2,mysqld3;--error 1149STOP INSTANCE mysqld1,mysqld2,mysqld3;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -