Adding a MySQL user when no MySQL users have admin rights?

7,943 pts.
Tags:
Database administration
MySQL
SQL
Ubuntu
I'm working on a MySQL installation that has a user already created ("admin"), but that user doesn't have a password, and doesn't have any permissions, so I can't create new users or even reset the password of that user.
I'm using Ubuntu Server, and after looking through the help files I still can't find a way to add a user when the only existing user has no permissions. Am I missing something basic? Is there a way to add a super user from the command line before going into the MySQL command line?
Thanks!
ASKED: April 27, 2011  6:33 PM
UPDATED: April 28, 2011  7:39 AM

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Subhendu Sen
    Yes, u may add a Super user Try out this.... First, stop the mysql service by: /etc/init.d/mysql stop Now, start mysql in safe mode in background..... /usr/bin/mysqld_safe --skip-grant-tables & Now pass the command as: mysql --user=root mysql From here u may set the new one on mysql prompt.... mysql> update user set Password=PASSWORD WHERE User='root'; Again, pass the command as: flush privileges; then type as: exit
    26,090 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following