| 1 |
source include/have_ndb.inc; |
| 2 |
|
| 3 |
# Nodes: |
| 4 |
# NDB 1,2 |
| 5 |
# MGM 3 |
| 6 |
# API 16,32,48,49,63,127 |
| 7 |
|
| 8 |
# Save now to only look at new info in EventLog |
| 9 |
select now() into @now; |
| 10 |
|
| 11 |
# DUMP signals in use: |
| 12 |
# CmvmiRelayDumpStateOrd(103003) to-node dump-state-ord ... |
| 13 |
# CmvmiDummy(103004) report-to sent-from padding frag-size #sec sec#1-len ... |
| 14 |
# CmvmiSendDummy(103005) report-to send-to padding frag-size #sec sec#1-len ... |
| 15 |
|
| 16 |
# Signals internal to data node do not use transporters and associated buffers. |
| 17 |
# Sections are stored in segmented long message buffers without explicit size |
| 18 |
# limits. |
| 19 |
let $section_size=32768; |
| 20 |
echo section size 3x$section_size: DB(1) -> DB(1); |
| 21 |
exec $NDB_MGM -e |
| 22 |
"1 DUMP 103005 1 1 1234567890 0 3 $section_size $section_size $section_size"; |
| 23 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 24 |
|
| 25 |
# Message size is sum of: |
| 26 |
# mandatory Protocol6 header: 3 words |
| 27 |
# signal id: 0 or 1 word |
| 28 |
# signal data size: 7 word (if dump commands are changed this may change) |
| 29 |
# section lengths: 1 word (one word per section used) |
| 30 |
# section data: $section_size |
| 31 |
# checksum: 0 or 1 word |
| 32 |
|
| 33 |
echo * Send biggest supported messages *; |
| 34 |
|
| 35 |
# For MGM and API internal signal no signal id or checksum are used in messages. |
| 36 |
|
| 37 |
let $section_size=8177; |
| 38 |
let $msg_size=`select 3 + 0 + 7 + 1 + $section_size + 0`; |
| 39 |
|
| 40 |
echo size $msg_size: MGM(3) -> MGM(3); |
| 41 |
exec $NDB_MGM |
| 42 |
-e "1 DUMP 103003 3 103005 1 3 1234567890 0 1 $section_size"; |
| 43 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 44 |
|
| 45 |
echo size $msg_size: API(16) -> API(16); |
| 46 |
exec $NDB_MGM |
| 47 |
-e "1 DUMP 103003 16 103005 1 16 1234567890 0 1 $section_size"; |
| 48 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 49 |
|
| 50 |
# For external signals signal id and checksum are used in messages. |
| 51 |
|
| 52 |
let $section_size=8176; |
| 53 |
let $msg_size=`select 3 + 1 + 7 + 1 + $section_size + 1`; |
| 54 |
|
| 55 |
echo size $msg_size: DB(2) -> DB(1); |
| 56 |
exec $NDB_MGM -e "2 DUMP 103005 1 1 1234567890 0 1 $section_size"; |
| 57 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 58 |
|
| 59 |
echo size $msg_size: DB(1) -> API(32); |
| 60 |
exec $NDB_MGM -e "1 DUMP 103005 1 32 1234567890 0 1 $section_size"; |
| 61 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 62 |
|
| 63 |
let $section_size=8175; |
| 64 |
let $msg_size=`select 3 + 1 + 7 + 1 + $section_size + 1`; |
| 65 |
|
| 66 |
echo size $msg_size: MGM(3) -> DB(1); |
| 67 |
exec $NDB_MGM |
| 68 |
-e "1 DUMP 103003 3 103005 1 1 1234567890 0 1 $section_size"; |
| 69 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 70 |
|
| 71 |
echo size $msg_size: API(16) -> DB(1); |
| 72 |
exec $NDB_MGM |
| 73 |
-e "1 DUMP 103003 16 103005 1 1 1234567890 0 1 $section_size"; |
| 74 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 75 |
|
| 76 |
sleep 1; |
| 77 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 78 |
|
| 79 |
echo * Fail send messages bigger than 32KiB bytes *; |
| 80 |
|
| 81 |
# For MGM and API internal signal no signal id or checksum are used in messages. |
| 82 |
|
| 83 |
let $section_size=8181; |
| 84 |
let $msg_size=`select 3 + 0 + 7 + 1 + $section_size + 0`; |
| 85 |
|
| 86 |
echo size $msg_size: MGM(3) -> MGM(3); |
| 87 |
exec $NDB_MGM |
| 88 |
-e "1 DUMP 103003 3 103005 1 3 1234567890 0 1 $section_size"; |
| 89 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 90 |
|
| 91 |
echo size $msg_size: API(16) -> API(16); |
| 92 |
exec $NDB_MGM |
| 93 |
-e "1 DUMP 103003 16 103005 1 16 1234567890 0 1 $section_size"; |
| 94 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 95 |
|
| 96 |
# For external signals signal id and checksum are used in messages. |
| 97 |
|
| 98 |
let $section_size=8179; |
| 99 |
let $msg_size=`select 3 + 1 + 7 + 1 + $section_size + 1`; |
| 100 |
|
| 101 |
echo size $msg_size: DB(2) -> DB(1); |
| 102 |
exec $NDB_MGM -e "2 DUMP 103005 1 1 1234567890 0 1 $section_size"; |
| 103 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 104 |
|
| 105 |
echo size $msg_size: DB(1) -> API(32); |
| 106 |
exec $NDB_MGM -e "1 DUMP 103005 1 32 1234567890 0 1 $section_size"; |
| 107 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 108 |
|
| 109 |
let $section_size=8179; |
| 110 |
let $msg_size=`select 3 + 1 + 7 + 1 + $section_size + 1`; |
| 111 |
|
| 112 |
echo size $msg_size: MGM(3) -> DB(1); |
| 113 |
exec $NDB_MGM |
| 114 |
-e "1 DUMP 103003 3 103005 1 1 1234567890 0 1 $section_size"; |
| 115 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 116 |
|
| 117 |
echo size $msg_size: API(16) -> DB(1); |
| 118 |
exec $NDB_MGM |
| 119 |
-e "1 DUMP 103003 16 103005 1 1 1234567890 0 1 $section_size"; |
| 120 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 121 |
|
| 122 |
sleep 1; |
| 123 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 124 |
|
| 125 |
echo * Fail send messages limited by send buffers but not bigger than 32KiB *; |
| 126 |
|
| 127 |
# For MGM and API internal signal no signal id or checksum are used in messages. |
| 128 |
|
| 129 |
let $section_size=8181; |
| 130 |
let $msg_size=`select 3 + 0 + 7 + 1 + $section_size + 0`; |
| 131 |
|
| 132 |
echo size $msg_size: MGM(3) -> MGM(3); |
| 133 |
exec $NDB_MGM |
| 134 |
-e "1 DUMP 103003 3 103005 1 3 1234567890 0 1 $section_size"; |
| 135 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 136 |
|
| 137 |
echo size $msg_size: API(16) -> API(16); |
| 138 |
exec $NDB_MGM |
| 139 |
-e "1 DUMP 103003 16 103005 1 16 1234567890 0 1 $section_size"; |
| 140 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 141 |
|
| 142 |
# For external signals signal id and checksum are used in messages. |
| 143 |
|
| 144 |
let $section_size=8179; |
| 145 |
let $msg_size=`select 3 + 1 + 7 + 1 + $section_size + 1`; |
| 146 |
|
| 147 |
echo size $msg_size: DB(2) -> DB(1); |
| 148 |
exec $NDB_MGM -e "2 DUMP 103005 1 1 1234567890 0 1 $section_size"; |
| 149 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 150 |
|
| 151 |
echo size $msg_size: DB(1) -> API(32); |
| 152 |
exec $NDB_MGM -e "1 DUMP 103005 1 32 1234567890 0 1 $section_size"; |
| 153 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 154 |
|
| 155 |
let $section_size=8179; |
| 156 |
let $msg_size=`select 3 + 1 + 7 + 1 + $section_size + 1`; |
| 157 |
|
| 158 |
echo size $msg_size: MGM(3) -> DB(1); |
| 159 |
exec $NDB_MGM |
| 160 |
-e "1 DUMP 103003 3 103005 1 1 1234567890 0 1 $section_size"; |
| 161 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 162 |
|
| 163 |
echo size $msg_size: API(16) -> DB(1); |
| 164 |
exec $NDB_MGM |
| 165 |
-e "1 DUMP 103003 16 103005 1 1 1234567890 0 1 $section_size"; |
| 166 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 167 |
|
| 168 |
sleep 1; |
| 169 |
exec $NDB_MGM -e "ALL REPORT EventLog" >> $NDB_TOOLS_OUTPUT; |
| 170 |
|
| 171 |
create temporary table ndb_output ( |
| 172 |
idx int auto_increment primary key, |
| 173 |
output_line blob |
| 174 |
); |
| 175 |
|
| 176 |
disable_query_log; |
| 177 |
eval |
| 178 |
load data local infile '$NDB_TOOLS_OUTPUT' |
| 179 |
into table ndb_output |
| 180 |
character set binary |
| 181 |
fields terminated by '\r' |
| 182 |
(output_line, @dummy); |
| 183 |
enable_query_log; |
| 184 |
|
| 185 |
select |
| 186 |
substr(output_line, 21) |
| 187 |
from ndb_output |
| 188 |
where |
| 189 |
output_line like '%Dummy%' |
| 190 |
and substr(output_line, 1, 20) >= @now |
| 191 |
group by output_line |
| 192 |
order by |
| 193 |
substr(output_line, instr(output_line, 'size')), |
| 194 |
substr(output_line, 21) desc; |
| 195 |
|
| 196 |
drop table ndb_output; |
| 197 |
|
| 198 |
remove_file $NDB_TOOLS_OUTPUT; |