Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to install the python module "mysql" on Windows 7 with apache installed with AppServ (installation includes Apache, MySQL and PHP).

When I try to run the setup.py script of "python-mysql" I get error

serverKey = _winreg.OpenKey(_winreg.HKEY_LOCAL_MACHINE, options['registry_key'])
WindowsError: [Error 2] The system cannot find the file specified

The problem is that it can not find the registry of MySQL. So I opened regedit and looked under the default location (which was specified in setup.py) - SOFTWARE\MySQL AB\MySQL Server 5.1 under HKEY_LOCAL_MACHINE.

However, I found that this location does not exist on my computer, and after searching a bit I found that under HKEY_USERS I do have "AppServ" under SOFTWARE, but MySQL Server is no where to be found!

Anyone had any experience with this issue and knows where I should point the config?

Thanks! Joel

share|improve this question

1 Answer 1

I added it manually and entered to String values for "Version" and "Location" (which I mapped to the bin folder of my MySQL installation path). Then you need to update site.cfg with the same key value you added those strings under in your registry. That should work barring other issues. Mine did not compile due to Python being compiled with Visual Studio... grrr. Hope this helps you though!

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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