cant delete mysql user

mamady

Member
Jun 15, 2002
11
0
151
I have one domain which when mysql users are created, they cannot be deleted (via phpmyadmin). When a user is granted permission to a database, and the user is then deleted, it simply APPEARS deleted, but i can still see the mysql user in the root WHM section to 'change passwords for mysql users'.

When the database is deleted, and a database of the same name is created again, the old user automatically reappears with permissions already granted. (this wouldnt really be a problem, but scripts trying to use mysql under this domain are not working correctly)

Very weird and confusing... but what i really need to know is... how do i manually delete mysql users? Anybody come across this before? If so, how did you fix it?
 

bert

Well-Known Member
Aug 21, 2001
593
0
316
We have the same problem here. It has been like that for weeks now.
 

MarlboroMan

Well-Known Member
Dec 7, 2001
64
0
306
To delete a mysql user's privledges....
# mysql
& REVOKE ALL
ON [dbname].*
From [username];

Additional info on GRANT and REVOKE syntax can be found at mysql's website.....
http://www.mysql.com/doc/en/GRANT.html
 

mamady

Member
Jun 15, 2002
11
0
151
thanks... i actually did a search and found that the user does not exist. It must be a cpanel/WHM problem.

here are the commands to see if your user exists:
[email protected]# mysql
mysql&use mysql;
mysql&select * from user where user='database_user';



Any ideas on how to fix this problem?
 

bert

Well-Known Member
Aug 21, 2001
593
0
316
Quite weird. I know-how and can create dbs, users, etc via the command line, however i was referring to Cpanel. The Cpanel mysql screen is the one that has a problem removing users from databases. It has been like that for months now I believe.
 

mamady

Member
Jun 15, 2002
11
0
151
on restarting mysql, this is what i

get: mysql started ok Aug 11 05:19:35 alpha kernel: grsec: setreuid(ruid=0/euid=0) by (mysqlwrap:1716) UID(32004) EUID(0), parent (cpanel:10689) UID(32004) EUID(32004)

What does that mean? Is the kernel having problems?