본문 바로가기

리눅스

[리눅스] mariadb 비밀번호 재설정하기

728x90

mariadb 비밀번호 재설정하기

MariaDB 접속 오류

$ mysql -uzabbix_user -p'zabbixpw1!' zabbix_proxy_db
ERROR 1045 (28000): Access denied for user 'zabbix_user'@'localhost' (using password: YES)

MariaDB 비밀번호 재설정

root로 접속

mysql -uroot -p
use mysql;
MariaDB [(none)]> use mysql;
update user set password=password('zabbixpw1!') where user='zabbix_user';
MariaDB [mysql]> update user set password=password('zabbixpw1!') where user='zabbix_user';
flush privileges;
quit

MariaDB 접속

mysql -uzabbix_user -p'zabbixpw1!' zabbix_proxy_db
$ mysql -uzabbix_user -p'zabbixpw1!' zabbix_proxy_db
MariaDB [zabbix_proxy_db]>

 

728x90