1SET @start_global_value = @@global.slave_checkpoint_period; 2SELECT @start_global_value; 3@start_global_value 4300 5select @@global.slave_checkpoint_period; 6@@global.slave_checkpoint_period 7300 8select @@session.slave_checkpoint_period; 9ERROR HY000: Variable 'slave_checkpoint_period' is a GLOBAL variable 10show global variables like 'slave_checkpoint_period'; 11Variable_name Value 12slave_checkpoint_period period 13show session variables like 'slave_checkpoint_period'; 14Variable_name Value 15slave_checkpoint_period period 16select * from information_schema.global_variables where variable_name='slave_checkpoint_period'; 17VARIABLE_NAME VARIABLE_VALUE 18SLAVE_CHECKPOINT_PERIOD period 19select * from information_schema.session_variables where variable_name='slave_checkpoint_period'; 20VARIABLE_NAME VARIABLE_VALUE 21SLAVE_CHECKPOINT_PERIOD period 22set global slave_checkpoint_period=1; 23select @@global.slave_checkpoint_period; 24@@global.slave_checkpoint_period 251 26set session slave_checkpoint_period=1; 27ERROR HY000: Variable 'slave_checkpoint_period' is a GLOBAL variable and should be set with SET GLOBAL 28set global slave_checkpoint_period=1.1; 29ERROR 42000: Incorrect argument type to variable 'slave_checkpoint_period' 30set global slave_checkpoint_period=1e1; 31ERROR 42000: Incorrect argument type to variable 'slave_checkpoint_period' 32set global slave_checkpoint_period="foo"; 33ERROR 42000: Incorrect argument type to variable 'slave_checkpoint_period' 34set global slave_checkpoint_period=1; 35select @@global.slave_checkpoint_period; 36@@global.slave_checkpoint_period 371 38set global slave_checkpoint_period=cast(-1 as unsigned int); 39Warnings: 40Warning 1292 Truncated incorrect slave_checkpoint_period value: '18446744073709551615' 41select @@global.slave_checkpoint_period as "truncated to the maximum"; 42truncated to the maximum 434294967295 44SET @@global.slave_checkpoint_period = @start_global_value; 45SELECT @@global.slave_checkpoint_period; 46@@global.slave_checkpoint_period 47300 48