What would fundamentally change with MySQL between using XAMP or WAMPserver so as to render MySQL inaccessible, triggering a MySQL 2003 error code?

Last Sunday I was comparing XAMPP with Wampserver. I used the same MySQL database. I approached the experiment from the analogous point of view of using the two different basic text editors to edit the same simple text document. Both packages run the same version of MySQL. I was not successful getting Wampserver to do what I thought it could do. There were no changes to data, just trying to access it. I did not succeed with getting wampserver to access an alias, never mind submit a query to MySQL Yet, I could not get MySQL under XAMPP to run until I did a restore of certain MySQL files to a state prior to any testing.

The files I restored were:
desktop.err
desktop.pid
data.frm
data.myd
data.myi

The last 3 files are specific to a database project I am working on, so I do not think those were a factor. That leaves desktop.err or desktop.pid (both in the folder that serves as the root for MySQL data).

Any thoughts?

Recommended Answers

All 3 Replies

Hi there,
2003 is "can't connect to MySQL server" right?

I don't think that just restoring the files did the magic - if you didn't previously delete them in the first place :-)
desktop.err is error log (your computer is called "desktop")
desktop.pid is socket number where MySQL is connected to (normally you shouldn't touch this file, restarting MySQL is better)

Did you try restarting the MySQL server when you got the 2003 error?
net stop MySQL
net start MySQL
(from Windows command line; or using Services console)

When you try starting the MySQL server and it won't start, have a look into the error file desktop.err it should tell you why. If there's nothing there then the problem might be Windows related in which case take a look into Windows Event Viewer / Applications.

I hope you kept the original desktop.err before you overwrote it with the backup copy. If you didn't then well, we're talking just academically here. ;-)

P.S.: This thread should be better off in Databases forum, not PHP. But let's finish it when we're here.

2003 is "can't connect to MySQL server" right?

Right

I don't think that just restoring the files did the magic

I didn't think it should have done the trick either, hence my post.

Did you try restarting the MySQL server when you got the 2003 error?
net stop MySQL
net start MySQL
(from Windows command line; or using Services console)

Using XAMPP, I don't have Apache and MySQL installed as services. Through the XAMPP control panel I tried to start MySQL as a service but not even that could overcome whatever was preventing MySQL from starting.

When you try starting the MySQL server and it won't start, have a look into the error file desktop.err it should tell you why. If there's nothing there then the problem might be Windows related in which case take a look into Windows Event Viewer / Applications.

I did not look in the desktop.err log. I hate to sound like such a newb, but I find the error log to be less than helpful whem I'm trying to resolve issues like this. I didn't think of the Windows Event Viewer / Applications until you mentioned it. Going back through it, there's nothing entered around the time I was wrangling with this challenge.

I hope you kept the original desktop.err before you overwrote it with the backup copy. If you didn't then well, we're talking just academically here. ;-)

I didn't keep the existing one before the restore. :( It was late, I was tired and frustrated that I couldn't do any coding that evening.

P.S.: This thread should be better off in Databases forum, not PHP. But let's finish it when we're here.

You're right. I wasn't thinking straight when I posted the original thread (see the 3 factors above).

My apologies to the forum for putting this thread in the wrong forum.

Hi dwlamb_001,
I use xampp myself and I do have MySQL and Apache installed as services. Your situation could be different though.

Starting MySQL from xampp control panel should be just fine, although I'm not sure if MS DOS window pop ups and stays open for you to read error messages if there are any. If it doesn't show up or stay open, you'd probably want to find the executables that do the starting and run them in MS DOS window manually. I'm pretty sure the Control panel is just GUI, it just calls executables to do the requested work.

On my system these executables are:
C:\xampp\mysql_start.bat
C:\xampp\mysql_stop.bat

Because you said you wanted to run xampp and wamp (I'm not familiar with this one) with the same MySQL server, I deduce that you already had MySQL installed on your box. So perhaps xampp executables were trying to start MySQL from xampp distribution which you didn't install. Or worse, you did install another MySQL with xampp and it collided with your old MySQL server.

In order to run two different MySQL servers, you have to tune up their configuration file my.cnf so that they listen to different ports (I'm not sure about socket numbers, hopefully they're assigned automatically) and use different data directory.

I'm not sure but it appears to me that we came to an end. Could you please mark this thread as closed? Or ask more questions if you have any.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.