Sorry, a mysql user with the name * already exists.

ipvhost.ro

Registered
Oct 8, 2009
4
0
51
Hello

I have terminate an account, and I wanted to restore it from backup but I get this error:

Account Creation Status: failed (Sorry, a mysql user with the name th454 already exists.)

Account Restore Failed... Restore failed.

I verify from shell, and I was able to create the user th454, actually user does not exist before:
mysql> CREATE USER 'th454'@'localhost' IDENTIFIED BY 'some_pass';
Query OK, 0 rows affected (0.00 sec)


After I drop the user:
mysql> DROP USER 'th454'@'localhost';
Query OK, 0 rows affected (0.01 sec)


Now I try again to restore the account but:

Account Creation Status: failed (Sorry, a mysql user with the name th454 already exists.)

Account Restore Failed... Restore failed.


Conclusion: The user does not exist, but cpanel sees the user there.

thanks,
 

JaredR.

Well-Known Member
Feb 25, 2010
1,834
23
143
Houston, TX
cPanel Access Level
Root Administrator
First, check a second time for any MySQL user by that name:

Code:
mysql> use mysql;
mysql> select User, Host from user where User like '%th454%';
After confirming that no MySQL user by that name exists, look in /var/cpanel/databases/users.db. If the user is listed there, remove it.

If this does not help, please submit a ticket. I have seen a few isolated instances of this happening in recent versions of the product, and if there is a problem that is causing this to happen, we need to be able to look directly at examples so that we may isolate and identify any potential problem.
 

lbeachmike

Well-Known Member
Dec 27, 2001
306
1
316
Long Beach, NY
cPanel Access Level
Root Administrator
Any fix for this yet? I have just encountered this for the second time in about a week.

The number of bugs that are impacting critical day-to-day functionality of cpanel operation seems to be at an all time high.

I specifically run the stable build because I am trying to avoid these types of scenarios.

Perhaps cpanel needs to re-evaluate its process for releasing a build as stable.

Thanks.

mrk
 

twigs76pc

Registered
Feb 12, 2012
1
0
51
cPanel Access Level
Website Owner
I am also having the same issue, and I have submitted a ticket, #2283798 to support. I am running WHM 11.30.6 (build 3) on CENTOS 6.2 i686 virtuozzo at Interserver.net. I gave them access to the server to help diagnose the issue. I have also looked at my user.db and the affected user (noodlent) does not exist. However, when I go to 'Manage Wheel Group Users', the user shows up there.

Anyone else come up with a solution yet?

UPDATE: From Michael Photakis, Technical Analyst 2 at cPanel:

"Hello.

It looks like that user is still present in your passwd files, and in /etc/dbowners. You'll need to manually remove the user from the dbowners file, and you'll probably want to run "userdel noodlent" to remove the user from your passwd files."

This is what solved my issue. Hope it helps someone else.
 
Last edited: