Akses akun root mariadb tanpa password

Untuk akses root mariadb biasanya memerlukan password. Tapi sebenarnya root bisa diakses tanpa password. Pertama, hentikan dulu service mariadb-nya.

$ /etc/rc.d/rc.mysqld stop

Kemudian, restart database server tanpa peduli otentikasinya.

$ mariadbd-safe --skip-grant-tables --skip-networking &

Nah, akun root mariadb sudah bisa diakses tanpa password

$ mariadb -u root
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 3
Server version: 10.11.2-MariaDB Source 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)]> 

Oiya, 3 command pertama dijalankan dengan privilege root yang ada di sistem di mana mariadb tersebut diinstall.

 Share!

 
comments powered by Disqus