This would seems to prevent attackers who know that a 'root' user exists?

link|improve this question

80% accept rate
Exactly would you imagine to gain from that, in relation to having a solid root password? – andol Jun 7 '10 at 4:52
Because having to guess a username and password is twice as hard at just guessing the password? – PoppySeeds Jun 7 '10 at 5:10
No, because the username isn't meant to be a secret, hence the system will put much less efforts into hiding/protecting it. If you want to increase the amounts of possible combination you will get a much better effect by simply making your password longer. – andol Jun 12 '10 at 19:39
feedback

1 Answer

up vote 5 down vote accepted

Don't remove the MySQL 'root' user, just rename it instead:

mysql> update user set user="somecrazyname" where user="root";
mysql> flush privileges;

I can't rightly imagine what will happen if you go deleting the root user.

link|improve this answer
It wouldn't make any difference for MySQL if you removed the initial 'root' user but you wouldn't be able to create any more databases/tables etc. if your other users don't have the right privileges. – joschi Jun 7 '10 at 7:41
feedback

Your Answer

 
or
required, but never shown

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