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

Razakel

Registered
Nov 9, 2010
1
0
51
I reinstalled my server and imported an SQL dump, then removed all the MySQL users. Now when I try to recreate an account I get the error:

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

despite it not existing.

I'm guessing users are cached somewhere, anyone know where?
 

activa

Well-Known Member
May 23, 2006
213
1
168
Morocco
cPanel Access Level
Root Administrator
the same error here .

the user is for a old account was already removed .

i have tried to remove it by command and it fail !!!

Code:
DROP USER xxx ;
ERROR 1396 (HY000): Operation DROP USER failed for xxxx;
 

hekri

Well-Known Member
Oct 14, 2003
147
2
168
the same problem, any one from cpanel cat fix it?


The same problem o 12 dedicated servers when we termitate accout and want to create account with the same username
 

JaredR.

Well-Known Member
Feb 25, 2010
1,834
23
143
Houston, TX
cPanel Access Level
Root Administrator
We ask that anyone experiencing this problem please submit a ticket so that we may log into your server and investigate this directly. If there is a bug in the product that is causing this to happen, we need to see affected servers so that we can isolate and identify the bug and fix it.
 

hekri

Well-Known Member
Oct 14, 2003
147
2
168
What for you need login data to the server? Test in on your local server.


We have the same situation on all 12 dedicated servers Centos 5 (32 and 64bit)

Example acount abc

Terminate acount abc
Create account abc

Account creavtion failed!
Sorry, a mysql user with the name abc already exists.
 

JaredR.

Well-Known Member
Feb 25, 2010
1,834
23
143
Houston, TX
cPanel Access Level
Root Administrator
I have not been able to duplicate this on a test server. It is important to recognize that production servers can have very different environments, and this can make duplicating your exact situation on one of our test servers difficult or impossible. We do not take lightly the request for log-in information, and all log-in information is handled in a secure manner, and all access to customers' servers is done using secure methods.
 

Cindu

Well-Known Member
Feb 7, 2011
46
0
56
Hey!!:rolleyes:

Thumbs up to cPanel Techs! There is nothing harm in giving them login informations. You will get a faster solution if you give them that! ( My personal experience)
 

cPanelDavidN

Well-Known Member
Staff member
Dec 17, 2009
571
3
68
Houston, TX
cPanel Access Level
Root Administrator
@hekri
How quickly are you deleting and recreating the cPanel account? When you delete an account, some parts of the deletion process (which include MySQL drop/revoke/flush stuff) are send to a queue for processing. That is, those processes don't happen instantaneously along with the WHM interface (or API request). So, when you delete an account, the cPanel database index is queue for updating...but when you attempt to recreate the account before the index has time to be rebuilt (remember it's in a process queue), you'll receive that error. Usually, a simple delay (10-30secs) between deletion and creation preempt this error.

But like Jared said, there are many things at play here and we recommend opening a support ticket so we can investigate the problem within you specific environment.

Regards,
-DavidN
 

Xavior82

Active Member
PartnerNOC
Oct 5, 2006
30
0
156
Montreal
One of my reseller clients just reported this same problem (and I confirmed) on v11.28.86, so you guys may want to look into some mechanism for preventing this in the future...
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
38
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
As requested previously in this thread, if you are experiencing this issue, please submit a ticket using either WHM > Support Center > Contact cPanel or the link in my signature. Please post the ticket number here upon opening one.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
38
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
Have you opened up a ticket about the issue? If the proposed suggestions in this thread do not resolve the issue, the course of action requested is to open up a ticket.
 

xisn

Well-Known Member
Dec 4, 2004
136
5
168
cPanel Access Level
Root Administrator
I know this is a bit of an old thread however I am experiencing the same issue here... In addition to this error, the users see no databases when clicking the "MySQL Databases" link.

I also tried to run the command "/scripts/updateuserdatacache" which also did not resolve this issue for me either.

Ticket #: 1630138
 
Last edited:

CyberFunk

Registered
Jun 26, 2011
4
0
51
Log into your webserver as root and run:
grep -Rl USERNAME /var/cpanel/databases/

You will get a list of files where needed username is still placed.:)
 
Last edited:

PvUtrix

Well-Known Member
Mar 12, 2005
58
1
156
Ekaterinburg - Russia
cPanel Access Level
Root Administrator
I've come across the same problem

running grep -Rl combat /var/cpanel/databases/

shows 2 results
/var/cpanel/databases/users.db.cache
/var/cpanel/databases/users.db


How can I remove the user from there?

I've tried running /usr/local/cpanel/bin/setupdbmap

and checked /var/cpanel/databases no user or related DBs there
 
Last edited: