MariaDB Authentication Plugin [ Unix Socket ]

호밀빵 굽는 쿼카·2023년 1월 31일
1

MariaDB

목록 보기
1/1

...(작성중)...
...(완성글 아님 주의)...

상황

이슈 발생

  • MariaDB(verion_10.3.31) CentOS 환경 초기접속 명령어 mysql -u root 사용 시 정상 접속
[centos@mariadb-origin ~]$ mysql -u root
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 8
Server version: 10.3.31-MariaDB-log MariaDB Server
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]>
  • MariaDB(version_10.6.11) Ubuntu 환경 초기접속 명령어 mysql -u root 사용 시 access denied error 발생. 대신 sudo mysql -u root 를 사용하면 정상 접속
ubuntu@mariadb-test:~$ mysql -u root
ERROR 1698 (28000): Access denied for user 'root'@'localhost'
ubuntu@mariadb-test:~$ sudo mysql -u root
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 36
Server version: 10.6.11-MariaDB-1:10.6.11+maria~ubu2004 mariadb.org binary distribution
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> 

예상 원인

1) OS 의 차이로 인한 접속 명령어 차이
2) Version 의 차이로 인한 접속 명령어 차이
정답은 2) 였습니다.



Unit Soket

MariaDB 공식 document 에 나와있는 내용으로는, MariaDB 10.4.3 이후로는
Unit Soket 이라는 변경된 인증방식을 사용한다고 합니다.

profile
열심히 굽고 있어요🍞

0개의 댓글