#! /bin/sh /usr/share/dpatch/dpatch-run ## 93_fix_user_setup_on_localhost.dpatch by Daniel Hahler ## ## All lines beginning with `## DP:' are a description of the patch. ## DP: No description. @DPATCH@ diff -urNad mysql-dfsg-5.0-5.0.51a~/scripts/mysql_system_tables_data.sql mysql-dfsg-5.0-5.0.51a/scripts/mysql_system_tables_data.sql --- mysql-dfsg-5.0-5.0.51a~/scripts/mysql_system_tables_data.sql 2008-01-11 15:43:26.000000000 +0100 +++ mysql-dfsg-5.0-5.0.51a/scripts/mysql_system_tables_data.sql 2008-04-28 20:57:08.084428731 +0200 @@ -18,6 +18,6 @@ REPLACE INTO tmp_user VALUES (@@hostname,'root','','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','','','','',0,0,0,0); REPLACE INTO tmp_user VALUES ('127.0.0.1','root','','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','','','','',0,0,0,0); INSERT INTO tmp_user (host,user) VALUES ('localhost',''); -INSERT INTO tmp_user (host,user) VALUES (@@hostname,''); +REPLACE INTO tmp_user (host,user) VALUES (@@hostname,''); INSERT INTO user SELECT * FROM tmp_user WHERE @had_user_table=0; DROP TABLE tmp_user;