PT-1575 Fix pt-mysql-summary to recognize PXC

This commit is contained in:
Carlos Salguero
2019-03-20 12:32:25 -03:00
parent 39aa1f88f0
commit 06582008fd

View File

@@ -2358,10 +2358,9 @@ report_mysql_summary () {
section_percona_server_features "$dir/mysql-variables" section_percona_server_features "$dir/mysql-variables"
section "Percona XtraDB Cluster" section "Percona XtraDB Cluster"
local has_wsrep="$(get_var "wsrep_on" "$dir/mysql-variables")" local has_wsrep=$($CMD_MYSQL $EXT_ARGV -ss -e 'show session variables like "%wsrep_on%";' | cut -f2 | grep -i "on")
if [ -n "${has_wsrep:-""}" ]; then if [ -n "${has_wsrep:-""}" ]; then
local wsrep_on="$(feat_on "$dir/mysql-variables" "wsrep_on")" if [ "${has_wsrep:-""}" = "ON" ]; then
if [ "${wsrep_on:-""}" = "Enabled" ]; then
section_percona_xtradb_cluster "$dir/mysql-variables" "$dir/mysql-status" section_percona_xtradb_cluster "$dir/mysql-variables" "$dir/mysql-status"
else else
name_val "wsrep_on" "OFF" name_val "wsrep_on" "OFF"