Bug #74341 command line client does not run from start menu in Win7.
Submitted: 12 Oct 2014 15:29 Modified: 2 Jun 2015 22:24
Reporter: Peter Laursen (Basic Quality Contributor) Email Updates:
Status: Closed Impact on me:
Category:MySQL for Windows: Installer Severity:S3 (Non-critical)
Version:5.6.21, 5.7.5 OS:Windows (7/64)
Assigned to: CPU Architecture:Any

[12 Oct 2014 15:29] Peter Laursen
Since upgrade to latest 5.6 and 5.7 the mysql client cannot connect to server when launched from startmenu shortcut. It 'flickers' for a moment and then disappears. Latest 5.1 and 5.5 are not affected - they run from start menu.

I can connect with GUI clients and also mysql frm cmd.exe like this

C:\Program Files\MySQL\MySQL Server 5.6\bin>mysql -uroot -p --port=3310
Enter password: ********
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.6.21-log MySQL Community Server (GPL)

Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.


Latest 5.1 and 5.5 are not affected.

A detail to notice is that I skipped configration wizard when upgrading. So the actual configuraton is unchanged

How to repeat:
Click the start menu icon created by the isntaller. A command window opens for a fraction of a second and then closes again.

Suggested fix:
My best guess is that it tries to connect on the wrong port. From the icon context menu I cann see thiscommand 

"C:\Program Files\MySQL\MySQL Server 5.6\bin\mysql.exe" "--defaults-file=C:\Program Files\MySQL\MySQL Server 5.6\my.ini" "-uroot" "-p"

-- but If I am right it seems not to read the defaults file, where the port is specified, properly.  

From the my.ini that used to work:  

# pipe
# socket=mysql



[12 Oct 2014 15:36] Peter Laursen
OK .. this exlain I think:

Runningtehcommand in cmd.exe:

C:\Users\Peter>"C:\Program Files\MySQL\MySQL Server 5.6\bin\mysql.exe" "--defaul
ts-file=C:\Program Files\MySQL\MySQL Server 5.6\my.ini" "-uroot" "-p"
Could not open required defaults file: C:\Program Files\MySQL\MySQL Server 5.6\m
Fatal error in defaults handling. Program aborted

[12 Oct 2014 15:47] Peter Laursen
Got it!

Defaults file is not in C:\Program Files but in C:\Program Data. The file path in the command executed from the start menu icon is wrong!  After editing it is OK.

This is actually an issue and a regresson with the MySQL Installer latest version then!  

Changing category from clients to installer.
[12 Oct 2014 21:31] MySQL Verification Team
Thank you for the bug report.
[24 Oct 2014 11:03] Peter Laursen
So I wonder if the installer package was replaced on the server without re-versoning it? If so, this is a very bad practice IMO. How should users know the difference, if it happened?

It is fine that/if - more or less - trivial fixes in the installer does not wait for a new server release. But in that case you should add a suffix to the file name (mysql-installer-community-, mysql-installer-community- etc.) for instance.
[14 May 2015 0:04] Jose Gabriel Valencia Ornelas
Posted by developer:
This is no longer happening with Installer 1.4.6 and 1.4.7 please try latest installer again!