Skip to content

Commit f988a23

Browse files
authored
Merge pull request major#306 from ofigueroa/bugfix_unitialized_value
Resolved issue major#304
2 parents 48be29a + adb33d3 commit f988a23

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

mysqltuner.pl

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5041,28 +5041,28 @@ sub mariadb_galera {
50415041
having sum(if(c.column_key in ('PRI','UNI'), 1,0)) = 0"
50425042
);
50435043

5044-
if (get_wsrep_option('wsrep_slave_threads') > `nproc`*4 or get_wsrep_option('wsrep_slave_threads') < `nproc`*3) {
5045-
badprint "wsrep_slave_threads is not equal to 3 or 4 times number of CPU(s)";
5046-
push @adjvars, "wsrep_slave_threads= Nb of Core CPU * 4";
5044+
if ($myvar{'wsrep_slave_threads'} > `nproc` * 4 or $myvar{'wsrep_slave_threads'} < `nproc` * 2) {
5045+
badprint "wsrep_slave_threads is not equal to 2 or 4 times number of CPU(s)";
5046+
push @adjvars, "wsrep_slave_threads= Nb of Core CPU * 2";
50475047
} else {
5048-
goodprint "wsrep_slave_threads is equal to 3 or 4 times number of CPU(s)";
5048+
goodprint "wsrep_slave_threads is equal to 2 or 4 times number of CPU(s)";
50495049
}
50505050

5051-
if (get_wsrep_option('gcs.limit') != get_wsrep_option('wsrep_slave_threads') *5 ) {
5052-
badprint "gcs.limit should be equal to 5 * wsrep_slave_threads";
5053-
push @adjvars, "gcs.limit= wsrep_slave_threads * 5";
5051+
if (get_wsrep_option('gcs.fc_limit') != $myvar{'wsrep_slave_threads'} * 5 ) {
5052+
badprint "gcs.fc_limit should be equal to 5 * wsrep_slave_threads";
5053+
push @adjvars, "gcs.fc_limit= wsrep_slave_threads * 5";
50545054
}
50555055
else {
5056-
goodprint "gcs.limit is equal to 5 * wsrep_slave_threads";
5056+
goodprint "gcs.fc_limit is equal to 5 * wsrep_slave_threads";
50575057
}
50585058
if (get_wsrep_option('gcs.fc_factor') == 0.8 ) {
50595059
badprint "gcs.fc_factor should be equal to 0.8";
50605060
push @adjvars, "gcs.fc_factor=0.8";
50615061
}
50625062
else {
5063-
goodprint "gcs.limit is equal to 5 * wsrep_slave_threads";
5063+
goodprint "gcs.fc_limit is equal to 5 * wsrep_slave_threads";
50645064
}
5065-
if (get_wsrep_option('wsrep_flow_control_paused') > 0.02) {
5065+
if ($mystat{'wsrep_flow_control_paused'} > 0.02) {
50665066
badprint "Fraction of time node pause flow control > 0.02";
50675067
}
50685068
else {

0 commit comments

Comments
 (0)