by looking at the pattern defined in the server. Currently I'm using
hard-coded stuff which matches personal usage.
-2. Only tested on MySQL 5.6 and MariaDB 10.0. It should be possible
-to make this work on MySQL 5.7 but that has not been tested yet.
-
-3. Latency issues over slow connections. Perhaps should use compressed
+2. Latency issues over slow connections. Perhaps should use compressed
connection to speed things up?
-4. Sometimes I see this:
+3. Sometimes I see this:
pstop 0.0.12 - 8:46:41 xxxxxxxxxxxxx / 5.6.21-log, up 1d 22h 59m 16s [ABS]
Latency by Table Name (table_io_waits_summary_by_table) 239 rows
with a very long latency. Related to doing backups. Need to check the cause
of the 5124.10h ++ issue. Probably a subtraction problem of some sort.
-5. Fix the filename encoding for example in sys:
+4. Fix the filename encoding for example in sys:
sys.x@0024host_summary_by_sta 882.29 us 0.2%| 3.5% 96.5%| 100 | 30 33.3% 66.7%
sys.x@0024host_summary_by_fil 861.65 us 0.2%| 3.6% 96.4%| 100 | 30 33.3% 66.7%
"log"
)
-// check that select to a table exists. Return an error if we get a failure.
+// Check that select to a table works. Return an error if we get a failure.
func CheckTableAccess(dbh *sql.DB, table_name string) error {
sql_select := "SELECT 1 FROM " + table_name + " LIMIT 1"
* +----------------+
* 1 row in set (0.00 sec)
**/
+
+// return the variable value of the given variable name (if found), or if not an error
func SelectGlobalStatusByVariableName(dbh *sql.DB, variable_name string) (error, int) {
sql_select := "SELECT VARIABLE_VALUE from INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = ?"
logger *log.Logger
}
+// Enable logging to the log file
func (logger *MyLogger) EnableLogging(enable_logging bool) bool {
if logger.logging_enabled == enable_logging {
return enable_logging // as nothing to do
-// Top like progream which collects information from MySQL's
+// pstop - Top like progream which collects information from MySQL's
// performance_schema database.
package main