创建一个已经存在过的用户,即使已经执行过 delete from mysql.user where User='gerrit'
再重新创建也会报错,如下(gerrit账号是已经存在过,并且delete的):
mysql> CREATE USER 'gerrit'@'localhost' IDENTIFIED BY 'gerrit';
ERROR 1396 (HY000): Operation CREATE USER failed for 'gerrit'@'localhost'
解决方案:
drop user "gerrit"@"localhost";