Bug #51264 MySQL.prefPane fails to run
Submitted: 18 Feb 2010 3:50 Modified: 19 Jan 2011 1:30
Reporter: Felix Fung Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Installing Severity:S3 (Non-critical)
Version:5.1.43-osx10.4-i686, 5.1.50, 5.5.6 OS:MacOS (10.4.11)
Assigned to: Hery Ramilison CPU Architecture:Any
Tags: preference pane

[18 Feb 2010 3:50] Felix Fung
Description:
After installing mysql-5.1.43-osx10.4-i686.pkg from the DMG archive and then MySQL.prefPane, subsequently running the preference panes results in an error alert:

"Preference Error

Could not load MySQL preference pane."

How to repeat:
Open mysql-5.1.43-osx10.4-i686.dmg
Clean install mysql-5.1.43-osx10.4-i686.pkg
Double-click to install MySQL.prefPane
Open System Preferences and attempt to launch MySQL preference pane
Receive error
[3 Mar 2010 10:43] Sveta Smirnova
Thank you for the report.

I can not repeat described behavior. Please try current version 5.1.44 and if problem still exists provide MySQL error log file and /var/log/system.log (really only MySQL related entries needed)
[25 Mar 2010 15:22] Eric Rasmussen
I'm using the 5.1.45 Os X 10.4 32-bit executable and am seeing the same behavior trying to install the Preferences Pane.

mysqld is running and I can use mysql, I see nothing mysql related in /var/log/system.log and both "SHOW ERRORS" and "SHOW WARNINGS" return an empty result set.

Trying to install the Preferences Pane I get the same error whether I'm a standard user (need an admin user password prompt) or whether I am an admin user, and whether I try to install the preferences pane for all users or just this user.

I've successfully installed and used the Preferences Pane before on an Os X 10.5 machine.
[3 Apr 2010 23:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[6 Apr 2010 6:36] Sveta Smirnova
Eric,

thank you for the feedback. What happens if you stop mysql, then install PrefPane?
[8 Apr 2010 18:37] Eric Rasmussen
I still get the same behavior.  That is, after stopping MySQL and verifying that the server process is not running, I can install the Preference Pane in the panel.  But after a reboot, clicking on it produces a "Could not load MySQL preference pane" error.
[8 Apr 2010 18:45] Eric Rasmussen
I still get the same behavior.  That is, after stopping MySQL and verifying that the server process is not running, I can install the Preference Pane in the panel.  But after a reboot, clicking on it produces a "Could not load MySQL preference pane" error.
[19 May 2010 19:15] sue sugizaki
Hi!

version: mysql-5.1.46-osx10.4-i686
OS: 10.4.11

Trying to install the prefPane, but just seeing "Preference error, could not load mySQL".
[28 Jul 2010 6:48] Sveta Smirnova
All reporters.

Please try new version 5.1.49 and inform us if it was occasionally fixed.
[11 Aug 2010 22:59] William Merritt
I just installed the mysql-5.1.49-osx10.4-i686.dmg and I'm getting the error message 

Could not load MySQL preference pane.

I'm not a techy sort, however my job is asking me to learn SQL to do some minor database maintenance. 
Any help with getting the preference pane installed would be great, as I can't seem to get my terminal to allow me to access mysql from it...

Thanks
[11 Sep 2010 8:53] Herve GOUANVIC
Installing of mysql-5.1.50-osx10.4-i686.dmg  on Mac OS X Version 10.4.11 (Build 8S2169) and placing the MySQL.prefPane in /Library/PreferencePanes, 
the error in the console log is :
loading code /Library/PreferencePanes/MySQL.prefPane/Contents/MacOS/MySQL for bundle /Library/PreferencePanes/MySQL.prefPane, error code 4 (link edit error code 4, error number 0 (Symbol not found: ___stack_chk_guard
  Referenced from: /Library/PreferencePanes/MySQL.prefPane/Contents/MacOS/MySQL
  Expected in: /usr/lib/libSystem.B.dylib
))
2010-09-11 09:57:01.801 System Preferences[25820] [NSPrefPaneBundle instantiatePrefPaneObject] (/Library/PreferencePanes/MySQL.prefPane): principalClass is nil.
[13 Sep 2010 18:49] Sveta Smirnova
Herve,

thank you for the feedback.

I was finally able to repeat the problem. I firstly installed server, then prefPane, then got error.
[24 Sep 2010 8:09] Russell Jameson
Hi, just experiencing the same thing...
PowerBook G4, OSX 10.4.11
mysql-5.1.50-osx10.4-i686

Loaded mysql and started server ok
Pref pane installed but comes up with "Preferences Error", "Could not load MYSQL"

2010-09-24 08:17:43.021 System Preferences[381] *** -[NSBundle load]: Error loading code /Users/russ/Library/PreferencePanes/MySQL.prefPane/Contents/MacOS/MySQL for bundle /Users/russ/Library/PreferencePanes/MySQL.prefPane, error code 4 (link edit error code 4, error number 0 (Symbol not found: ___stack_chk_guard
  Referenced from: /Users/russ/Library/PreferencePanes/MySQL.prefPane/Contents/MacOS/MySQL
  Expected in: /usr/lib/libSystem.B.dylib
[29 Sep 2010 10:38] Susanne Ebrecht
Bug #55530 was set as duplicate of this bug here
[29 Sep 2010 10:38] Sveta Smirnova
Bug #53232 was marked as duplicate of this one. Repeatable on Snow Leopard too.
[8 Oct 2010 21:27] Sveta Smirnova
Bug #57151 was marked as duplicate of this one.
[11 Oct 2010 9:48] Sveta Smirnova
Bug #57361 was marked as duplicate of this one.
[20 Oct 2010 12:47] Alvaro Oliveira
I was able to reproduce the problem on 10.6.4

I just had a mysql 5.1 version working, deleted everything for a clean install

Downloaded the new 5.5rc package (32bits), installed. 

The installation was OK, the PrefPane got installed. 

But if I click Start Server, it prompts for my admin password, and after that it just
stays there. It won't do anything, does not show any errors, but does not start the
server.

If I start from the command line, it works perfectly. The PrefPane is able to show that
the server is running.

The PrefPane *is* able to stop the server properly.

This is the error that shows up in the Mac OS Console Log :
10/20/10 10:45:25
AM	[0x0-0x39039].com.apple.systempreferences[2494]	/usr/local/mysql/support-files/mysql.server:
line 256: my_print_defaults: command not found

Thanks.
[20 Oct 2010 13:01] Alvaro Oliveira
I've fixed my issue described above my editing the "/usr/local/mysql/support-files/mysql.server" file

I've changed line 46. I've added my installation dir (which was the default)

basedir=/usr/local/mysql

The PrefPane is now working.
[29 Oct 2010 6:33] Michael Twisdale
Alvaro, 

cudos for your methodical and deductive thinking ... yesterday, I had exactly the same issue when upgrading to version 5.5 64 bit on Snow Leopard .... 

you know how much time your work saved me! .... a simple change to Line 46, as you described worked instantly .. 

(Actually, I change a few line down as follows
       # line 46 in my mysql.server is: 
       basedir=
       # so I change the next occurrence as follows inside the if statement ...
      if test -z "$basedir"
      then
      # **** ==> the above line commented out ==> basedir=.
      # **** ==> replaced with Alvaro solution ******** 
      basedir=/usr/local/mysql
      # ..... etc 
)

thanks for sharing ... and thanks also to everyone who took the time to describe the problem ...
[11 Nov 2010 18:19] Ash Searle
This is still a problem on 5.5.7

As noted before, the problem can be fixed by editing mysql.server.  I've got things working by making the script change working directory as soon as possible:

cd $(dirname "$0")/..

This is almost the same as saying 'cd /usr/local/mysql' and letting the script determine appropriate values for basedir from there - but without the hard-coding.
[23 Nov 2010 20:52] Sveta Smirnova
Bug #58420 was marked as duplicate of this one.
[17 Dec 2010 23:06] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/127231

3212 Jonathan Perkin	2010-12-17
      bug#51264: MySQL.prefPane fails to run
      
      @prefix@ was erroneously set to '.' with the STANDALONE install
      layout, when it should instead be set to CMAKE_INSTALL_PREFIX,
      this was likely accidentally copied from scripts/CMakeLists.txt
      which has similar handling specifically for mysql_install_db.sh
      
      mysql.server init script can now find the install, assuming the
      defaults have been chosen.
[22 Dec 2010 21:30] Bugs System
Pushed into mysql-trunk 5.6.1 (revid:alexander.nozdrin@oracle.com-20101222212842-y0t3ibtd32wd9qaw) (version source revid:alexander.nozdrin@oracle.com-20101222212842-y0t3ibtd32wd9qaw) (merge vers: 5.6.1) (pib:24)
[29 Dec 2010 12:52] Bugs System
Pushed into mysql-5.5 5.5.9 (revid:alexander.nozdrin@oracle.com-20101229113652-km2v993aurv7h79j) (version source revid:alexander.nozdrin@oracle.com-20101229113132-uonlbcc2uopff8yb) (merge vers: 5.5.9) (pib:24)
[19 Jan 2011 1:30] Paul DuBois
Noted in 5.5.9 changelog.

On Mac OS X, a configuration error caused the preference pane to fail.
[27 Feb 2011 3:07] Mithun Kumar
I got the 5.5.9 version of MySQL (Mac OS X 10.5 (x86, 64-bit), DMG Archive), and installed it from the pkg files.
Also followed the tips mentioned in http://jaykhimani.blogspot.com/2010/12/mysql-55-startup-problems-on-os-x-1065.html to start it up.

However as mentioned in this bug that the preference pane issue is resolved with 5.5.9 is incorrect. The prefpane given in the dmg of 5.5.9 does not even start on intel-based mac. I replaced it with the prefpane given under MySQL 5.1.51 and it's working like a charm, even starting up the 5.5.9 successfully.
[27 Feb 2011 5:02] Mithun Kumar
Ok please ignore my previous comment...
I downloaded the mysql-5.5.9-osx10.6-x86_64 DMG file and everything's working perfectly fine :P
[6 Mar 2011 8:50] Mich?le Garoche
System: Mac OS X 10.5.8
Architecture: Intel
MySQL package: mysql-5.5.9-osx10.5-x86_64.dmg

Same behaviour as reported above:
The preferences pane issues an error at installation: This preference pane cannot run on Intel architecture

Workaround only available for users having a previous installation of mysql:
Replace the preferences pane from version 5.5.9 with preferences pane from version 5.1.x
It works.

It would be nice that the dmg file be changed with a preferences pane which works correctly on Mac OS X 10.5 with Intel Architecture (aka for example iMac 20 Intel Core 2 Duo).