From ceb5689d506197ffb2269c6c64a8ea0802d55aba Mon Sep 17 00:00:00 2001 From: Matthijs Kooijman Date: Thu, 1 Jan 2009 20:46:01 +0100 Subject: [PATCH] mysql: pass options consistently when listing databases. r495 improved the database listing command, but only did this for the non-vserver case. This corrects that. --- handlers/mysql.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/handlers/mysql.in b/handlers/mysql.in index 39c1fb9..7ff194e 100644 --- a/handlers/mysql.in +++ b/handlers/mysql.in @@ -235,8 +235,8 @@ then then if [ $usevserver = yes ] then - debug 'echo show databases | $VSERVER $vsname exec su $user -c \"$MYSQL $defaultsfile\" | grep -v Database' - databases=`echo 'show databases' | $VSERVER $vsname exec su $user -c "$MYSQL $defaultsfile" | grep -v Database` + debug "$VSERVER $vsname exec su $user -c \"$MYSQL $defaultsfile -N -B -e 'show databases'\" | sed 's/|//g;/\+----/d'" + databases=`$VSERVER $vsname exec su $user -c "$MYSQL $defaultsfile -N -B -e 'show databases'" | sed 's/|//g;/\+----/d'` if [ $? -ne 0 ] then fatal "Authentication problem, maybe user/password is wrong or mysqld is not running?" -- 2.30.2