Package: mysql-server-5.0
Version: 5.0.22-1bpo1
Severity: minor
Tags: patch
/usr/bin/mysql_upgrade, which is called out of /etc/mysql/debian-start,
fails to look the /etc/mysql/debian.cnf file for socket or port
information, and thusly fails.
included patch modifies mysql_upgrade to check /etc/mysql/debian.cnf for
'port' and/or 'socket' statements.
-- System Information:
Debian Release: 3.1
Architecture: i386 (i686)
Kernel: Linux 2.4.20
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Versions of packages mysql-server-5.0 depends on:
ii adduser 3.63 Add and remove users and groups
ii debconf [debconf-2.0] 1.4.30.13 Debian configuration management sy
ii libc6 2.3.2.ds1-22sarge3 GNU C Library: Shared libraries an
ii libdbi-perl 1.46-6 Perl5 database interface by Tim Bu
ii libgcc1 1:3.4.3-13 GCC support library
ii libmysqlclient15off 5.0.22-1bpo1 mysql database client library
ii libncurses5 5.4-4 Shared libraries for terminal hand
ii libreadline5 5.0-10 GNU readline and history libraries
ii libstdc++5 1:3.3.5-13 The GNU Standard C++ Library v3
ii libwrap0 7.6.dbs-8 Wietse Venema's TCP wrappers libra
di mysql-client-5.0 5.0.22-1bpo1 mysql database client binaries
ii mysql-common 5.0.22-1bpo1 mysql database common files (e.g.
ii passwd 1:4.0.3-31sarge5 change and administer password and
ii perl 5.8.4-8sarge3 Larry Wall's Practical Extraction
ii psmisc 21.5-1 Utilities that use the proc filesy
ii zlib1g 1:1.2.2-4.sarge.2 compression library - runtime
-- debconf information:
mysql-server-5.0/really_downgrade: false
mysql-server-5.0/start_on_boot: true
mysql-server-5.0/nis_warning:
mysql-server-5.0/postrm_remove_databases: false
* mysql-server-5.0/no_upgrade_with_isam_tables:
* mysql-server-5.0/mysql_install_db_notes:
mysql-server-5.0/mysql_update_hints1:
--- mysql_upgrade.orig 2006-06-07 15:21:09.000000000 -0500
+++ mysql_upgrade 2006-06-07 15:23:59.000000000 -0500
@@ -38,6 +38,8 @@
--basedir=*) MY_BASEDIR_VERSION=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--user=*) user=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--password=*) password=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
+ --socket=*) socket=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
+ --port=*) port=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--ldata=*|--data=*|--datadir=*) DATADIR=`echo "$arg" | sed -e
's/^[^=]*=//'` ;;
--force) force=1 ;;
--verbose) verbose=1 ;;
@@ -92,6 +94,13 @@
parse_arguments `$print_defaults $defaults mysqld mysql_upgrade`
parse_arguments PICK-ARGS-FROM-ARGV "$@"
+if test ! -z "$port"; then
+ socketportarg="--port=$port"
+fi
+if test ! -z "$socket"; then
+ socketportarg="$socketportarg --socket=$socket"
+fi
+
if test $help_option = 1
then
echo "MySQL utility script to upgrade database to the current server version"
@@ -179,7 +188,7 @@
then
echo "mysql_upgrade already done for this version"
fi
- $bindir/mysql_fix_privilege_tables --silent --user=$user
--password=$password $args
+ $bindir/mysql_fix_privilege_tables --silent --user=$user
--password=$password $socketportarg $args
exit 0
fi
fi
@@ -192,10 +201,10 @@
if test $verbose = 1
then
- echo "Running $bindir/mysqlcheck $args $check_args"
+ echo "Running $bindir/mysqlcheck $args $check_args $socketportarg"
fi
-$bindir/mysqlcheck $check_args $args
+$bindir/mysqlcheck $check_args $args $socketportarg
if [ $? = 0 ]
then
# Remember base version so that we don't run this script again on the
@@ -203,4 +212,4 @@
echo "5.0" > $CHECK_FILE
fi
-$bindir/mysql_fix_privilege_tables --silent --user=$user --password=$password
$args
+$bindir/mysql_fix_privilege_tables --silent --user=$user --password=$password
$args $socketportarg