Commit ef39d2a6 authored by lenz@mysql.com's avatar lenz@mysql.com

- applied patch from provided by Christian Hammers from Debian to be able

   to run the script even if mysqld is not up and running on upgrade
parent dd44f48f
#!/bin/sh
echo "This scripts updates the mysql.user, mysql.db, mysql.host and the"
echo "mysql.func tables to MySQL 3.22.14 and above."
echo ""
echo "This is needed if you want to use the new GRANT functions,"
echo "CREATE AGGREGATE FUNCTION or want to use the more secure passwords in 3.23"
echo ""
echo "If you get 'Access denied' errors, you should run this script again"
echo "and give the MySQL root user password as an argument!"
root_password="$1"
host="localhost"
user="root"
......@@ -20,6 +11,21 @@ else
cmd="@bindir@/mysql -f --user=$user --password=$root_password --host=$host mysql"
fi
# Debian addition
if [ "$1" = "--sql-only" ]; then
root_password=""
cmd="/usr/share/mysql/echo_stderr"
fi
echo "This scripts updates the mysql.user, mysql.db, mysql.host and the"
echo "mysql.func tables to MySQL 3.22.14 and above."
echo ""
echo "This is needed if you want to use the new GRANT functions,"
echo "CREATE AGGREGATE FUNCTION or want to use the more secure passwords in 3.23"
echo ""
echo "If you get 'Access denied' errors, you should run this script again"
echo "and give the MySQL root user password as an argument!"
echo "Converting all privilege tables to MyISAM format"
$cmd <<END_OF_DATA
ALTER TABLE user type=MyISAM;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment