Skip to content

Commit 27f1454

Browse files
committed
update comments and logging messages
1 parent 2e34761 commit 27f1454

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

mysqltuner.pl

+6-3
Original file line numberDiff line numberDiff line change
@@ -293,15 +293,18 @@ sub mysql_setup {
293293
exit 0;
294294
}
295295
} elsif ( -r "/etc/mysql/debian.cnf" and $doremote == 0 ){
296-
# It's a debian system, use the maintenance account
296+
# We have a debian maintenance account, use it
297297
$mysqllogin = "--defaults-file=/etc/mysql/debian.cnf";
298298
my $loginstatus = `mysqladmin $mysqllogin ping 2>&1`;
299-
unless ($loginstatus =~ /mysqld is alive/) {
299+
if ($loginstatus =~ /mysqld is alive/) {
300+
goodprint "Logged in using credentials from debian maintenance account.\n";
301+
return 1;
302+
} else {
300303
badprint "Attempted to use login credentials from debian maintenance account, but they failed.\n";
301304
exit 0;
302305
}
303306
} else {
304-
# It's not Plesk, we should try a login
307+
# It's not Plesk or debian, we should try a login
305308
my $loginstatus = `mysqladmin $remotestring ping 2>&1`;
306309
if ($loginstatus =~ /mysqld is alive/) {
307310
# Login went just fine

0 commit comments

Comments
 (0)