added tokudb captures if the engine is present

This commit is contained in:
Fernando Ipar
2015-05-12 13:34:32 -03:00
parent 66c74af47b
commit 02a2fffc28

View File

@@ -838,6 +838,7 @@ collect() {
local mutex="SHOW MUTEX STATUS"
fi
innodb_status 1
tokudb_status 1
$CMD_MYSQL $EXT_ARGV -e "$mutex" >> "$d/$p-mutex-status1" &
open_tables >> "$d/$p-opentables1" &
@@ -988,6 +989,7 @@ collect() {
fi
innodb_status 2
tokudb_status 2
$CMD_MYSQL $EXT_ARGV -e "$mutex" >> "$d/$p-mutex-status2" &
open_tables >> "$d/$p-opentables2" &
@@ -1055,13 +1057,20 @@ transactions() {
$CMD_MYSQL $EXT_ARGV -e "SELECT SQL_NO_CACHE * FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS\G"
}
tokudb_status() {
local n=$1
$CMD_MYSQL $EXT_ARGV -e "SHOW ENGINE TOKUDB STATUS\G" \
>> "$d/$p-tokudbstatus$n" || rm -f "$d/$p-tokudbstatus$n"
}
innodb_status() {
local n=$1
local innostat=""
$CMD_MYSQL $EXT_ARGV -e "SHOW /*!40100 ENGINE*/ INNODB STATUS\G" \
>> "$d/$p-innodbstatus$n"
>> "$d/$p-innodbstatus$n" || rm -f $d/$p-tokudbstatus$n
grep "END OF INNODB" "$d/$p-innodbstatus$n" >/dev/null || {
if [ -d /proc -a -d /proc/$mysqld_pid ]; then
for fd in /proc/$mysqld_pid/fd/*; do