Closed juliyvchirkov closed 7 years ago
Hi @juliyvchirkov
It's happening when the following commands failed: mysql> show variables; ERROR 1146 (42S02): Table 'performance_schema.session_variables' doesn't exist
You probably migrate from mariaDB or MySQL 5.X<7 without creating a new database and reimport dump.
I check this and get the same results. After you perform this migration operations all seems to be fine. Moreover, you will be able to monitor your database as well.
I closed this issue. MySQLTuner doesn't have to configure MySQL 5.7 with show_compatibility_56 is ON,
Please refer to migration notes here: https://dev.mysql.com/doc/refman/5.7/en/performance-schema-variable-table-migration.html
hello
mysqltuner script v1.7.0 fails on server running centos 6.8 (minimal install, no x [if this matters]) w/ perl v5.10.1 & mysql v5.7.15 (i.e. percona server v5.7.15-9) due to a number of uninitialized vars, viz. — $myvar{"version"} — $mysqlvermajor — $mystat{"Questions"}
I've turned debug on for output to provide as much data as possible
# /sbin/mysqltuner --debug
[--] Skipped version check for MySQLTuner script [DG] MySQL Client: /usr/bin/mysql would have been started with the following arguments: --port=3306 --socket=/var/lib/mysql/mysql.sock [DG] MySQL Client: /usr/bin/mysql [DG] /usr/bin/mysqladmin ping 2>&1 Please enter your MySQL administrative login: line 2 (
(W uninitialized). An undefined value was used as if it were already
defined. It was interpreted as a "" or a 0, but maybe it was a mistake.
To suppress this warning assign a defined value to your variables. line 2 (
Use of uninitialized value line 2 (
[!!] Your MySQL version is EOL software! Upgrade soon!
[OK] Operating on 64-bit architecture
root
Please enter your MySQL administrative password: [DG] Physical Memory: 4016533504 [DG] Swap Memory: 2113925120 [DG] PERFORM: SELECT VERSION() [DG] select_array: return code : 0 [DG] VERSION: 5.7.15 [DG] PERFORM: SHOW VARIABLES [DG] select_array: return code : 0 [DG] PERFORM: SHOW GLOBAL VARIABLES [DG] select_array: return code : 0 [DG] PERFORM: SHOW STATUS [DG] select_array: return code : 0 [DG] PERFORM: SHOW GLOBAL STATUS [DG] select_array: return code : 0 [DG] PERFORM: SHOW ENGINES [DG] select_array: return code : 0 [DG] $VAR1 = 'PERFORMANCE_SCHEMA YES Performance Schema NO NO NO'; [DG] PERFORM: SHOW SLAVE STATUS\G [DG] select_array: return code : 0 [DG] PERFORM: SHOW SLAVE HOSTS [DG] select_array: return code : 0 [DG] PERFORM: \s [DG] select_array: return code : 0 [DG] Current database => [DG] Current user => root@localhost [DG] SSL => Not in use [DG] Server version => 5.7.15-9-log Percona Server (GPL), Release 9, Revision f0e3400 [DG] Protocol version => 10 [DG] Connection => Localhost via UNIX socket [DG] Server characterset => utf8 [DG] Db characterset => utf8 [DG] Client characterset => utf8 [DG] Conn. characterset => utf8 [DG] UNIX socket => /var/lib/mysql/mysql.sock [DG] Uptime => 11 hours 26 min 46 sec Use of uninitialized value$myvar{"version"}
in pattern match (m//) at /var/lib/mysql/tuner/mysqltuner.pl line 1697,#1
)To help you figure out what was undefined, perl will try to tell you the name of the variable (if any) that was undefined. In some cases it cannot do this, so it also tells you what operation you used the undefined value in. Note, however, that perl optimizes your program and the operation displayed in the warning may not necessarily appear literally in your program. For example, "that $foo" is usually optimized into "that " . $foo, and the warning will refer to the concatenation (.) operator, even though there is no . in your program.
Use of uninitialized value
$mysqlvermajor
in int at /var/lib/mysql/tuner/mysqltuner.pl line 1724,#1
)$myvar{"version"}
in concatenation (.) or string at /var/lib/mysql/tuner/mysqltuner.pl line 1702,#1
)-------- Storage Engine Statistics -------- [DG] PERFORM: SHOW DATABASES
[ ... skipped ... ]
-------- Security Recommendations -------- Use of uninitialized value line 2 (
[DG] Password column = password
[DG] PERFORM: SELECT CONCAT(user, '@', host) FROM mysql.user WHERE TRIM(USER) = '' OR USER IS NULL
[DG] select_array: return code : 0
[DG] $VAR1 = [];
$myvar{"version"}
in pattern match (m//) at /var/lib/mysql/tuner/mysqltuner.pl line 1508,#1
)[OK] There are no anonymous accounts for any database users Use of uninitialized value line 2 (
[!!] No more password checks for MySQL version <=5.1
[!!] MySQL version <=5.1 are deprecated and end of support.
$mysqlvermajor
in int at /var/lib/mysql/tuner/mysqltuner.pl line 1736,#1
)-------- CVE Security Recommendations -------- Use of uninitialized value
$mysqlvermajor
in concatenation (.) or string at /var/lib/mysql/tuner/mysqltuner.pl line 1107, <$fh> line 1 (#1
) Use of uninitialized value$mysqlvermajor
in int at /var/lib/mysql/tuner/mysqltuner.pl line 1736, <$fh> line 1 (#1
) [DG] Comparing .0.0 with 4.0.20 : <= Use of uninitialized value$mysqlvermajor
in numeric eq (==) at /var/lib/mysql/tuner/mysqltuner.pl line 1113, <$fh> line 1 (#1
) Use of uninitialized value$mysqlvermajor
in concatenation (.) or string at /var/lib/mysql/tuner/mysqltuner.pl line 1107, <$fh> line 2 (#1
) Use of uninitialized value$mysqlvermajor
in int at /var/lib/mysql/tuner/mysqltuner.pl line 1736, <$fh> line 2 (#1
) [DG] Comparing .0.0 with 4.0.21 : <= Use of uninitialized value$mysqlvermajor
in numeric eq (==) at /var/lib/mysql/tuner/mysqltuner.pl line 1113, <$fh> line 2 (#1
) Use of uninitialized value$mysqlvermajor
in concatenation (.) or string at /var/lib/mysql/tuner/mysqltuner.pl line 1107, <$fh> line 3 (#1
) Use of uninitialized value$mysqlvermajor
in int at /var/lib/mysql/tuner/mysqltuner.pl line 1736, <$fh> line 3 (#1
)[ ... skipped 'cause of identical error thru the loop ... ]
[DG] Comparing .0.0 with 7.0.11 : <= Use of uninitialized value
$mysqlvermajor
in numeric eq (==) at /var/lib/mysql/tuner/mysqltuner.pl line 1113, <$fh> line 512 (#1
) [OK] NO SECURITY CVE FOUND FOR YOUR VERSION Use of uninitialized value$mystat{"Questions"}
in numeric lt (<) at /var/lib/mysql/tuner/mysqltuner.pl line 2059 (#1
) [!!] Your server has not answered any queries - cannot continue...[ ... script exits ... ]
I've also compiled & tried mysqltuner.pl w/ fresh perl v5.20.2 but unfortunately the result has been the same as above
hope it helps; if you need some additional information — you are welcome to request