403Webshell
Server IP : 172.67.216.182  /  Your IP : 172.69.176.157
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/ndb/t/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/server/mysql/src/mysql-test/suite/ndb/t/ndb_fk_addnode.test
-- source include/have_ndb.inc
-- source include/not_embedded.inc

create table t1(id1 int NOT NULL PRIMARY KEY, data char(8)) engine=ndb;
create table t2(id2 int NOT NULL PRIMARY KEY, id1 int, data char(8)) engine=ndb;
alter table t2 algorithm=inplace, add constraint id1 foreign key (id1) references t1(id1);

load data local infile 'suite/ndb/data/table_data10000.dat' into table t1 fields terminated by ' ' lines terminated by '\n' ignore 900 lines;
load data local infile 'suite/ndb/data/table_data10000.dat' into table t2 fields terminated by ' ' lines terminated by '\n' ignore 900 lines (@id, data) set id1 = @id, id2 = -@id;

## Check details of partitioning
--replace_regex /FragmentCount:/FragmentCount/ /HashMap:/HashMap/ /.*[=:#].*// /.*- .*// /[0-9]*\/[0-9]*\/id1/.../
--exec $NDB_DESC -dtest t1
--replace_regex /FragmentCount:/FragmentCount/ /HashMap:/HashMap/ /.*[=:#].*// /.*- .*// /[0-9]*\/[0-9]*\/id1/.../
--exec $NDB_DESC -dtest t2

## Create nodegroup for "new" nodes
--replace_regex /Connected to Management Server at: .*//
--exec $NDB_MGM -e "create nodegroup 3,4"

## Drop
--replace_regex /Connected to Management Server at: .*//
--exec $NDB_MGM -e "drop nodegroup 1"
## and create
--replace_regex /Connected to Management Server at: .*//
--exec $NDB_MGM -e "create nodegroup 3,4"

alter online table t2 reorganize partition;
alter online table t1 reorganize partition;

## Check details of partitioning
--replace_regex /FragmentCount:/FragmentCount/ /HashMap:/HashMap/ /.*[=:#].*// /.*- .*// /[0-9]*\/[0-9]*\/id1/.../
--exec $NDB_DESC -dtest t1
--replace_regex /FragmentCount:/FragmentCount/ /HashMap:/HashMap/ /.*[=:#].*// /.*- .*// /[0-9]*\/[0-9]*\/id1/.../
--exec $NDB_DESC -dtest t2

## Drop nodegroup with "new" nodes is not allowed with data one those nodes
# NOTE: --error=0 is due to return codes doesnt work on windoze
--replace_regex /Connected to Management Server at: .*//
--error 0,255
--exec $NDB_MGM -e "drop nodegroup 1"

drop table t2,t1;

## Drop nodegroup with "new" nodes
--replace_regex /Connected to Management Server at: .*//
--exec $NDB_MGM -e "drop nodegroup 1"

# Cleanup

Youez - 2016 - github.com/yon3zu
LinuXploit