2

So I can't even remember how this happened, I believe I was worried about how running

mysql -u root

Was allowing the root user to login without a password or even asking for one...

So I went down a rabbit hole and ran these codes like an idiot:

USE mysql;
DROP VIEW IF EXISTS user;
CREATE VIEW user AS SELECT * FROM mysql.global_priv;
FLUSH PRIVILEGES;

Once I ran that, everything was gone. I can't do anything with the root user other then access MariaDB in general (mysql -u root), but I'm not able to do anything. Running this causes an error saying I don't have the permissions to execute:

GRANT ALL PRIVILEGES ON  *.* to 'root'@'localhost' WITH GRANT OPTION;

I have tried everyhing... --skip-grant-tables, safe mode, etc - same errors and no results...

It seems like the mysql.user table is missing from what I could find too...

Let me know if there is any hope, or maybe I'll just have to re-install somehow

Thank you

1 Answer 1

1

I ended up backing up all my databases from cPanel backups, then uninstalled and re-installed MariaDB

Was much faster than myself messing around and waiting for an answer :/

Thank you

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.