summaryrefslogtreecommitdiff
path: root/scripts/mysql_install_db.sh
diff options
context:
space:
mode:
authorunknown <jani@ua141d10.elisa.omakaista.fi>2007-04-12 12:50:02 +0300
committerunknown <jani@ua141d10.elisa.omakaista.fi>2007-04-12 12:50:02 +0300
commit239b385933864bff3694f95ccc9d0c645f6a0aad (patch)
tree30b412b9ebad3ddaa08bcf7eb478c89eeebc2ed2 /scripts/mysql_install_db.sh
parentc4879fe6dde9890496a6555e78fa9bde5e21f8f4 (diff)
parentd2667d1a6ebe7feeb8b80fcc5cfefac80ed729b0 (diff)
downloadmariadb-git-239b385933864bff3694f95ccc9d0c645f6a0aad.tar.gz
Merge jamppa@bk-internal.mysql.com:/home/bk/mysql-5.0
into ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-5.0-marvel client/mysqldump.c: Auto merged mysql-test/t/sp.test: Auto merged mysys/my_malloc.c: Auto merged mysys/my_static.c: Auto merged mysys/safemalloc.c: Auto merged ndb/src/mgmclient/CommandInterpreter.cpp: Auto merged sql/ha_archive.cc: Auto merged sql/ha_innodb.cc: Auto merged sql/ha_ndbcluster.cc: Auto merged sql/handler.cc: Auto merged sql/item_cmpfunc.cc: Auto merged sql/item_func.h: Auto merged sql/log.cc: Auto merged sql/log_event.cc: Auto merged sql/mysql_priv.h: Auto merged sql-common/client.c: Auto merged sql/sp.cc: Auto merged sql/sp_head.cc: Auto merged sql/sql_delete.cc: Auto merged sql/sql_insert.cc: Auto merged sql/sql_show.cc: Auto merged sql/sql_table.cc: Auto merged sql/sql_update.cc: Auto merged sql/table.cc: Auto merged sql-common/my_time.c: Auto merged mysql-test/r/sp.result: Merged from main 5.0 sql/sql_load.cc: Merged from main 5.0
Diffstat (limited to 'scripts/mysql_install_db.sh')
-rw-r--r--scripts/mysql_install_db.sh28
1 files changed, 11 insertions, 17 deletions
diff --git a/scripts/mysql_install_db.sh b/scripts/mysql_install_db.sh
index 5dd5d86c666..c1a27eb0bc8 100644
--- a/scripts/mysql_install_db.sh
+++ b/scripts/mysql_install_db.sh
@@ -135,6 +135,17 @@ else
fi
fi
+# Check that no previous MySQL installation exist
+if test -f "$ldata/mysql/db.frm"
+then
+ echo "FATAL ERROR: Found already existing MySQL system tables"
+ echo "in $ldata."
+ echo "If you are upgrading from a previous MySQL version you"
+ echo "should run '$bindir/mysql_upgrade', "
+ echo "to upgrade all tables for this version of MySQL"
+ exit 1;
+fi
+
# Find SQL scripts needed for bootstrap
fill_help_tables="fill_help_tables.sql"
create_system_tables="mysql_system_tables.sql"
@@ -181,7 +192,6 @@ then
fi
# Find executables and paths
-mdata=$ldata/mysql
mysqld=$execdir/mysqld
mysqld_opt=""
scriptdir=$bindir
@@ -264,12 +274,6 @@ if test -w / -a ! -z "$user"; then
chown $user $ldata $ldata/mysql $ldata/test;
fi
-# Check is "db" table already exist
-if test ! -f $mdata/db.frm
-then
- db_table_already_exist="yes"
-fi
-
if test -n "$user"; then
args="$args --user=$user"
fi
@@ -322,16 +326,6 @@ then
echo "$bindir/mysqladmin -u root -h $hostname password 'new-password'"
echo "See the manual for more instructions."
- # Print message about upgrading unless we have created a new db table.
- if test -z "$db_table_already_exist"
- then
- echo
- echo "NOTE: If you are upgrading from a previous MySQL verision you "
- echo "should run '$bindir/mysql_upgrade', to make sure all tables have "
- echo "been upgraded for this version of MySQL"
- fi
- echo
-
if test "$in_rpm" = "0"
then
echo "You can start the MySQL daemon with:"