Bug #59000 Unable to add users to MySQL 5.5.8 (Windows 7 Ultimate x64) with GUI tools
Submitted: 17 Dec 2010 13:48 Modified: 10 Feb 2011 11:18
Reporter: Tim Thorburn Email Updates:
Status: Closed Impact on me:
Category:MySQL Workbench: Administration Severity:S1 (Critical)
Version:5.2.31a OS:Microsoft Windows (Win7 Ultimate 64-bit)
Assigned to: Maksym Yehorov CPU Architecture:Any
Tags: mysql 5.5.8, mysql administrator, windows, workbench

[17 Dec 2010 13:48] Tim Thorburn
Upon installing MySQL 5.5.8 on my Windows 7 Ultimate 64-bit dev machine I was unable to add users with either Workbench (5.2.31a) or MySQL Administrator.  The errors I received were as follows:

Unhandled exception: Error adding account accountName@%:

MySQL Administrator
Error while storing the user information. The user might have been
deleted. Please refersh the user list.

- a command prompt window appeared behind MySQL Administrator which stated the following:

** Message: save user: error adding new user entry 

How to repeat:
With MySQL 5.5.8 (64-bit) installed, start either MySQL Administrator or Workbench GUI tools.  Attempt to add a user, in the case of both GUI tools, this will fail.  When attempting to add a user via phpMyAdmin the operation is successful.

Suggested fix:
Correct issue with MySQL GUI tools to allow users to be added to MySQL 5.5.8
[18 Dec 2010 13:05] Marco Cianciaruso
I have the same identical problem on Win2008 Server
[18 Dec 2010 13:12] Marco Cianciaruso
I tried to use old "MySQL Administrator" .. same problem
I'd like to knwo how the developers tested the new server verision... all by command prompt?
[19 Dec 2010 3:45] Ryan Ellison
Same problem here -
 Upgraded from 5.1 to 5.5
 Windows 2008 R2 running MySQL x64
[19 Dec 2010 12:26] Peter Holliday
Exactly same issue on Vista
[19 Dec 2010 18:17] Alfredo Kojima
bug #58938 is a duplicate
[22 Dec 2010 11:10] Frederick Perry
Same problem. 
Windows 7 home premium.
Fresh install of 5.5.8 win32
Fresh install of workbench gpl 5.2.31a win32
First thing I did was try to add a new user instead of depending on root.
Bug produced as follows:
launch Workbench
double click "Local instance MySQL"
click "Accounts"
click "Add User"
fill in login form and hit apply.
[23 Dec 2010 2:26] Johnny C.L.
Same Problem Windows 2008 64bit
Error with WorkBench and Error with MySQL Administrator
[3 Jan 2011 21:33] Jim McHale
same issue on win7 ultimate x64.. 
any workarounds???
[3 Jan 2011 21:52] Peter Laursen
I believe that workaround is to execute GRANT statement(s) from the SQL editor interface - or from any other client. 

(Not a MySQL person)
[6 Jan 2011 6:28] Valeriy Kravchuk
Bug #59318 was marked as a  duplicate of this one.
[8 Jan 2011 2:22] Paulo Ferreira
I have the same problem, is there any solution?:
[8 Jan 2011 10:13] Peter Laursen
The solution/workaround is to execute a GRANT statement (from any client).

(not a MySQL person)
[8 Jan 2011 21:35] Rick Hubbard

In MySQL Workbench, I have only one account: 'root'@'localhost'.

Any attempt to ADD ACCOUNT (on a Win7 Ultimate 32-bit machine) also results in the problem mentioned above.

How can 'root' GRANT itself any privilege it doesn't already have?

Please provide further clarification...thanks!
[8 Jan 2011 21:53] Peter Laursen

For instance just execute the statement:
GRANT ALL ON *.* TO 'tim'@'localhost';
.. from any client (including the WB SQL editor) as a user with sufficient privileges.

(GRANT will implicitly CREATE USER, so CREATE USER statement will not need to be executed in advance).

As long as this is not fixed you cannot use WB GUI User Management with MySQL 5.5.7+.  

Options are 
1) execute a SQL GRANT statement from some editor/command line client tool
2) use GUI User Management of a GUI client that uses GRANT syntax internally (what at least SQLyog and HeidiSQL do).
3) INSERT INTO privileges tables + FLUSH PRIVILEGES -SQL statements (what WB seems to do internally - but fails as it does not handle the updated mysql.user table of 5.5.7+ if server is running 'strict mode'))
[12 Jan 2011 13:34] Maksym Yehorov
[12 Jan 2011 15:35] Josh Hyles
How do we get these changes? is there a nightly for workbench CE?
[12 Jan 2011 17:07] Maksym Yehorov
I do not know which next version of Workbench will include this fix. As an option I can attach a file that fixes the problem.
[12 Jan 2011 17:29] Leo Doms
I tried the grant workaround both from the workbench and from the mysql command line.
Result = ERROR 1133 (42000): Can't find any matching row in the user table
[12 Jan 2011 22:47] Marco Callegari
the same here, but i noticed i can create account from SQL Querybrowser, using the CRAETE USER statement, even in some way WB seems to hang on the account tab no more textboxes...
[12 Jan 2011 22:47] Marco Callegari
the same here, but i noticed i can create account from SQL Querybrowser, using the CRAETE USER statement, even in some way WB seems to hang on the account tab no more textboxes...
[14 Jan 2011 16:33] Juan Andrés Calleja
I have identical problem in Windows XP SP3 and Mysql 5.5.8 and MySql WorkBench 5.2.31 CE.

The programmers has not tested this app with Mysql 5.5.8 ?

One workaround is execute Create statement first in Sql Editor for create user (it's simply CREATE USER 'user' IDENTIFIED BY 'password') and after (in my case works fine) go to Admin tools/ Manage Accounts and set "schema privileges" (this is the heavy work with sql statements).

[18 Jan 2011 19:07] sammy esmail
I seem to have the exact error using Win7 Professional 64-bit Server running 6 XEON processors.

The error is:
Unhandled exception:Error adding account rf_user@%

So I have had to backout of mySQL 5.5.8 to mySQL 5.1.53.
I have tried this 3 different times. The GUI is busted. So how can we exploit the power of 5.5.8
[19 Jan 2011 21:02] Louis Breda van

I see someone is working on fixiing this bug, but I would neverthe less mention that I hope to see the fix for this IMHO critical this bug soon. 

The problem is caused by a change in the 558 server user administration. 
That is OK. But only as long as you have a tool to manage and ad users .....

So as far as me is concerned tha 558-server release can not be used before the WB is fixed.

[20 Jan 2011 7:53] Maksym Yehorov
I can say this again. The bug is fixed, it is in the internal processing. If anyone wish immediate fix, it is a one file copy and I can attach a file to this bug report with instructions. So far no one has been interested in this.
[20 Jan 2011 8:00] Yuriy Khramtsov
Maksym, provide the file and instructions please. Yuriy.
[20 Jan 2011 8:29] Maksym Yehorov
File which needs to be copied to fix the bug

Attachment: wb_admin_security_be.py (application/octet-stream, text), 33.19 KiB.

[20 Jan 2011 8:34] Maksym Yehorov
The file wb_admin_security_be.py is attached. It must be copied to the %MYSQL_WORKBENCH_INSTALLDIR%/modules in Windows or /usr/lib/mysql-workbench/modules in Linux(Ubuntu). There must be an older file with the same name.

Typical install dir for MySQL Workbench on Windows is %ProgramFiles%/MySQL/MySQL Workbench 5.2 ...
[20 Jan 2011 9:22] Yuriy Khramtsov
Thank you very much!
[20 Jan 2011 9:45] Juan Andrés Calleja
Thank you!
[20 Jan 2011 10:33] Louis Breda van

I will install the patch file and try

[24 Jan 2011 11:34] Daniel Candia
Hi Maksym, I had followed the instructions but the problem is the same. I have Windows 7 Home Premiun x64.
[26 Jan 2011 20:28] Johannes Taxacher
fix confirmed in repository
[26 Jan 2011 21:52] Johnny C.L.
Temporary FIX worked for me.
[28 Jan 2011 4:20] José Manuel Martínez
This fix works on Microsoft (R) Windows (R) Server 2003 Standard x64 Edition, but it seems that Workbench 5.2.31.CE Revision 7115, is not up to date.
Data Dump tab displays in log:
mysqldump.exe is version 5.1.40, but the MySQL Server to be dumped has version 5.5.8.
Because the version of mysqldump is older than the server, some features may not be backed up properly.
It is recommended you upgrade your local MySQL client programs, including mysqldump to a version equal to or newer than that of the target server.
The path to the dump tool must then be set in Preferences -> Administrator -> Path to mysqldump Tool:

 Thanks for the file, solves the main thing.
 Pepe Martinez
[3 Feb 2011 15:30] Johannes Taxacher
Bug #59914 has been marked as duplicate of this one
[3 Feb 2011 16:07] Valeriy Kravchuk
Bug #59921 was marked as a duplicate of this one.
[3 Feb 2011 16:30] Jiri Lexa
thanks for fix, I replaced file and it works now :).
[10 Feb 2011 11:18] Tony Bedford
An entry has been added to the 5.2.32 changelog:

Attempting to create a new user via MySQL Workbench failed with the following error:

Unhandled exception: Error adding account accountName@%:
[15 Feb 2011 21:23] Alex Haddad
On the following platform: Server version: 5.5.9 MySQL Community Server (GPL)
Using: MySQL Workbench 5.2.31CE Revision 7115
Get the following error:
WMIShell: Set filters for local windows cli

ctrl_be: Query Error Error executing 'You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '* Modify Access Control, CREATE ROUTINE, INDEX, SELECT, REPLICATION CLIENT, CREA' at line 1'


SQL Error: 1064

Traceback (most recent call last):

  File "C:\MySQL\MySQL Workbench 5.2 CE\modules\wb_admin_security.py", line 628, in commit


  File "C:\MySQL\MySQL Workbench 5.2 CE\modules\wb_admin_security_be.py", line 666, in save


  File "C:\MySQL\MySQL Workbench 5.2 CE\modules\wb_admin_security_be.py", line 633, in run_query

    raise Exception("Error creating account %s@%s: %s"%(self.username, self.host, e))

Exception: Error creating account cfweb@localhost: 

Then when I switch UI tabs and come back, the user is created but with no privileges. Tried adding privileges and then all is OK!
[15 Feb 2011 21:25] Alex Haddad
BTW, the error and behavior I reported happens after I updated the wb_admin_security_be.py with the contents posted by Maksym Yehorov.
[24 Feb 2011 7:05] Valeriy Kravchuk
Bug #60228 was marked as a duplicate of this one.
[23 Aug 2011 14:21] Aaron Harshbarger
Is there a fix for the MySQL Administrator Tool (v1.2.x)?  We don't want all the functionality that is in the workbench and our users are use to the GUI Tools pack (non-workbench).
[14 Feb 2013 4:16] Josh Unger
On Mac, /Applications/MySQLWorkbench.app/Contents/PlugIns/