Skip to content
Snippets Groups Projects
Commit c1bdf624 authored by Otto Kekäläinen's avatar Otto Kekäläinen Committed by Robert Bindar
Browse files

MDEV-18768: Rename auth_socket to unix_socket on upgrades from MySQL

This fixes bugs where upgrading MariaDB failed to start after an upgrade
from MySQL 5.7 in Ubuntu, where auth_socket has been the default for MySQL
as well for some time now.

This was adopted from Debian where this change has been since Apr 18, 2019:
mariadb-10.4@3919860b
parent edc3899d
No related branches found
No related tags found
No related merge requests found
......@@ -171,6 +171,14 @@ ALTER TABLE user
ALTER TABLE user
ADD Password char(41) character set latin1 collate latin1_bin NOT NULL default '' AFTER User;
# In MySQL the Unix socket authentication plugin has a different name. Thus the
# references to it need to be renamed in the user table. Thanks to the WHERE
# clauses this applies only to MySQL->MariaDB upgrades and nothing else.
UPDATE user
SET plugin='unix_socket' WHERE plugin='auth_socket';
DELETE FROM plugin
WHERE name='auth_socket';
ALTER TABLE user
MODIFY Password char(41) character set latin1 collate latin1_bin NOT NULL default '',
MODIFY Select_priv enum('N','Y') COLLATE utf8_general_ci DEFAULT 'N' NOT NULL,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment