Skip to content

Keep infoschema user since it is required for 8.0.4 #381

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 22, 2018

Conversation

yosifkit
Copy link
Member

Copying change from mysql@64fd620

Fixes #380

@tianon
Copy link
Member

tianon commented Feb 22, 2018

LGTM 👍

@@ -143,7 +143,7 @@ if [ "$1" = 'mysqld' -a -z "$wantHelp" ]; then
-- or products like mysql-fabric won't work
SET @@SESSION.SQL_LOG_BIN=0;

DELETE FROM mysql.user WHERE user NOT IN ('mysql.session', 'mysql.sys', 'root') OR host NOT IN ('localhost') ;
DELETE FROM mysql.user WHERE user NOT IN ('mysql.infoschema', 'mysql.session', 'mysql.sys', 'root') OR host NOT IN ('localhost') ;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this released?

mysql> SELECT user FROM mysql.user;
+---------------+
| user          |
+---------------+
| root          |
| mysql.session |
| mysql.sys     |
| root          |
+---------------+
4 rows in set (0.01 sec)

mysql> SELECT VERSION();
+-----------+
| VERSION() |
+-----------+
| 8.0.11    |
+-----------+
1 row in set (0.00 sec)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, instead the logic for removing unwanted users was removed from 5.7 and 8.0 completely (it was only needed for 5.5 and 5.6). But if you are upgrading from a version where the user wasn't present (either because it was an older version or it was mistakenly deleted) it won't be automatically recreated. Have you run mysql_upgrade?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I've made mistake with docker-compose and didn't dropped old volume. Works now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants