Forum Home
Press F1
 
Thread ID: 70529 2006-07-06 09:04:00 Starting MySQL in Debian Sarge jcr1 (893) Press F1
Post ID Timestamp Content User
469042 2006-07-06 09:04:00 Every time I try to start mysql on my Debian computer; I get this message;
"ERROR 2002: cant connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

I have looked high & low on google, but nothing there I can find that helps.
Checked the file /var/run/mysqld/mysqld.sock and there is nothing there; which puzzles me as the /etc/mysql/my.cnf file states quite categorically that it is the socket.

Can someone help with this please?
jcr1 (893)
469043 2006-07-06 10:04:00 Every time I try to start mysql on my Debian computer; I get this message;
"ERROR 2002: cant connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

I have looked high & low on google, but nothing there I can find that helps.
Checked the file /var/run/mysqld/mysqld.sock and there is nothing there; which puzzles me as the /etc/mysql/my.cnf file states quite categorically that it is the socket.

Can someone help with this please?

The real mysqld.sock may be installed somewhere else, so find it. Try locate mysqld.sock. You may have to update your locate database first: /usr/libexec/locate.updatedb (or whatever it is for Debian). Or find / -name mysqld.sock (may take a very long time). If you find another one, softlink /var/run/mysqld.sock to it.

You could also change /etc/my.cnf to reflect the other mysqld.sock file if it exists. Remember to back it up first: cp /etc/my.cnf /etc/my.cnf_bak.
vinref (6194)
469044 2006-07-06 10:54:00 Thanks vinref. I got it. I did another "apt-get install mysql 4.1 php-mysql 4.0"
(or something like that); it gave me the message that mysql was already installed, but gave me the option to continue with the rest, which I did.
Now it all works fine :thumbs: . I opened and closed it a couple of times, just to make sure and did a couple of simple example type data bases and it all works.
jcr1 (893)
469045 2006-07-06 11:36:00 the command netstat -a is also a good way of finding those pesky active sockets. With Debian everything should start like this: /etc/init.d/mysql start

Always a good idea to read up on any Debian specific installation settings in the folder /usr/share/doc/the package name/README.Debian
gibler (49)
469046 2006-07-07 22:08:00 Just a step further with this project.
I have been playing around with HTML, PHP and CSS; entering the code at a console on my Debian machine (it has no GUI - just command line stuff) and viewing the result on a browser on my WinXP machine. It works.
I use Filezilla to transfer files from windows to debian i.e. I have a directory called images in /var/www/WEB where I store photos to be used in this project.
To get a command line to do the job I use PuTTY. All this works pretty good but I would like to do the coding from the windows side (but actually having all the code placed in the appropriate place on debian), using one of those nifty GUI's that are available i.e. Eclipse.
Any ideas about how this could be set up?
jcr1 (893)
469047 2006-07-14 10:18:00 I've finally worked it out.
I tried ESftp with Eclipse; couldn't get it to work.
Then I got onto a program called sftpDrive, which works very well, kind of like samba, it allocates a drive e.g. e:, f:, etc. to linux and you have the choice which directories you want. I can then pick up which PHP file I want and open it in Eclipse to work with. Very slick :thumbs:
Downside is, its only a 6 week trial and at the end of it, it will cost $39 if I wish to keep using it.
Now all I have to do is find out how to do a similar thing with MySQL :confused:
jcr1 (893)
469048 2006-07-14 10:30:00 phpmyadmin (http://www.phpmyadmin.net/) ? gibler (49)
1