MySQL Error#: 2002

I am running on Mac OS 10.4.8 with Dreamweaver 8. PHP is
installed and working. MySQL is installed and working and running
at the time I get this message. I can enter SQL commands in the
terminal window and they work just fine.
The message occurs in Dreamweaver when I hit the test button
in the MySQL Connection dialog.
I have followed to the letter the advice given in Minh
Huynh's otherwise excellent article at "
http://www.adobe.com/devnet/dreamweaver/articles/php_macintosh.html"
Any help would be greatly appreciated.

Thanks for your answer. It was that I used an old database
connection! the host name got changed in the last year and I forgot
to put the new one!!;)

Similar Messages

  • MySQL error (2002) in Windows

    I'm using Dreamweaver 9 in Windows with a Apache, PHP5 and
    MySQL4.1. My webserver works fine. But Dreamweaver can't create
    database connection to MySQL. It gives me a MySQL error 2002 and
    referes to that /tmp/mysql.sock is missing.
    What should I do to get this to work? Am I missing something
    here? MySQL Query tool etc all work fine. But Dreamweaver can't
    connect to MySQL for some reason.

    chunkeung wrote:
    > When I login into
    > PHPMyAdmin I see that the Server is "Localhost via UNIX
    socket" so I put that
    > into my setting in dreamweaver for the "MySQL server"
    but on the hosting that
    > giving me that #2002 error message their Server is
    "127.0.0.1 via TCP/IP" and I
    > tried to put in 127.0.0.1 instead of localhost but it
    still doesn't work and
    > gives me this error message.
    localhost and 127.0.0.1 are the same thing. All you need is
    "localhost"
    or "127.0.0.1" (without the quotes). The "via UNIX socket"
    and "via
    TCP/IP" are simply descriptions of the type of connection.
    They are NOT
    part of the server address.
    David Powers, Adobe Community Expert
    Author, "The Essential Guide to Dreamweaver CS3" (friends of
    ED)
    Author, "PHP Solutions" (friends of ED)
    http://foundationphp.com/

  • MySQL Error#: 2002 Dreamweaver CS5

    HI
    Never had this problum before so not sure why now.  
    MySQL Error#:2002
    A connection attempt faild because the connected party did not properly respond after a period of time, or established connection faild because connected host has failed to respond
    Any help please?

    Thanks for your time Ken and I have uninstalled and reinstalled but its still the same.  The only thing I can think of is I installed zone alarm and since then its not work.

  • MySQL error 2002: No Such File or Directory in DW CS6

    OK, I've obviously configured something wrong in MYSQL or Dreamweaver, but despite exhaustive research, I can't connect to my database and I can't find a solution online.
    I'm running a Windows 7 Pro system. I installed PHP/MySQL/Apache all at once with a package called WAMPSERVER.
    The DB appears to be running properly. I am able to connect to it and make changes using my phpmyadmin. But no matter what configuration I try, I'm unable to get Dreamweaver CS6 to connect. As this is the same error I get when MYSQL is not working at all, I can surmise that Dreamweaver can't find my database, so what have I missed? Is my testing servr set up improperly? I don't see a lot of options here to do things differently.
    Can anyone offer any suggestions. Is there any other information I need to provide?

    Hi atomec,
    In the time that the experts get back to you, can you have a look at this post? http://stackoverflow.com/questions/10426501/how-to-solve-the-xampp-1-7-7-phpmyadmin-mysql- error-2002-in-ubuntu
    Thanks,
    Preran

  • MySQL Error 2002 when attempting to make a MySQL Connection

    I'm trying to make a MySQL Connection and I've got my Staging/Testing Server setup as FTP with the proper host, username and password for FTP, root directory set to '/' (without the quotation marks) and Web URL set to http://www.mysite.com/
    Tested the FTP and it connects.
    For mySQL connection in my bindings, I'm using:
    Connection Name; connRecords
    MySQL Server: localhost
    Username and then my Password for my DB which obviously I won't list here.
    I click Select Database and that's when I get the prompt:
    MySQL Error: #2002
    Can't connect to local MySQL Server through socket '/tmp/mysql.sock' (2)
    What does that mean and how do I get this to work?

    ladobeugm wrote:
    I click Select Database and that's when I get the prompt:
    MySQL Error: #2002
    Can't connect to local MySQL Server through socket '/tmp/mysql.sock' (2)
    What does that mean and how do I get this to work?
    On a Mac, connection to MySQL is done through a socket (mysql.sock). The fact that there's a (2) after mysql.sock indicates there's something wrong with the socket. Usually, you can clear the problem by powering down your computer and then restarting. Don't just do a restart. Make sure the computer switches off completely to clear the socket.

  • Mysql error 2002 & missing mysql.sock

    ok, I know this issue is all over the internet, however after reading many posts I have not been able to solve my issue. I hoping someone can help me out. Lets start with the error I get when typing "mysql start" in the terminal:
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2)
    I have mysql 5.0.51a x86_64 installed on my macbook pro, I used the package installer. I can tell you that the mysql.sock file is nowhere on my machine. It isn't in "private/var/mysql/ or private/tmp".
    I have the php.ini set to look for the socket like this: "mysql.default_socket = /var/mysql/mysql.sock" & "mysqli.default_socket = /var/mysql/mysql.sock"
    I have the my.cnf file set to:
    client (client is contained in square brackets)
    socket = /var/mysql/mysql.sock
    mysqld (mysqld is contained in square brackets)
    socket = /var/mysql/mysql.sock
    I cannot get mysql to start from the mysql preference panel or the terminal. How do I fix this missing socket file issue? Please help me I'm so frustrated by the fact I cannot get this worked out. Thanks in advance!

    http://discussions.apple.com/thread.jspa?messageID=5059320
    http://forums.macosxhints.com/archive/index.php/t-77067.html
    I've seen this before, on Tiger Server, personally. I think the php.ini change was what I did to resolve it. I can't recall for sure.

  • MySQL Error# : 2002 in Dreamweaver CS3

    I created a database in PHPMyAdmin for my site and when I try
    to connect to the DB from Dreamweaver I receive the error message #
    2002
    "Can't connect to local MySQL server through socket
    '/var/lib/mysql/mysql.sock'(s)"
    Does anyone have any idea how to fix that problem? I was able
    to get it works before but since I reformat my harddrive I keep
    getting this error message.
    Can anyone help me please? I'm running Win XP Pro SP2

    chunkeung wrote:
    > When I login into
    > PHPMyAdmin I see that the Server is "Localhost via UNIX
    socket" so I put that
    > into my setting in dreamweaver for the "MySQL server"
    but on the hosting that
    > giving me that #2002 error message their Server is
    "127.0.0.1 via TCP/IP" and I
    > tried to put in 127.0.0.1 instead of localhost but it
    still doesn't work and
    > gives me this error message.
    localhost and 127.0.0.1 are the same thing. All you need is
    "localhost"
    or "127.0.0.1" (without the quotes). The "via UNIX socket"
    and "via
    TCP/IP" are simply descriptions of the type of connection.
    They are NOT
    part of the server address.
    David Powers, Adobe Community Expert
    Author, "The Essential Guide to Dreamweaver CS3" (friends of
    ED)
    Author, "PHP Solutions" (friends of ED)
    http://foundationphp.com/

  • Dreamweaver CS5 mysql error

    Hi Im using the new Dreamweaver CS5, apache and php that the in the mac and mysql and I find a problem trying to make a connection in dreamweaver to the database the error is:
    MySQL Error: # 2002
    no such file or directory
    does anyone knows what could happening?

    Thanks for your time Ken and I have uninstalled and reinstalled but its still the same.  The only thing I can think of is I installed zone alarm and since then its not work.

  • Database error #2002 can not connect local mysql server to socket through '/var/run/mysqld/mysqld.sock'(2) on mac os x 10.9.2

    Dear Fellas:
    I received "database error #2002 can not connect local mysql server to socket through '/var/run/mysqld/mysqld.sock'(2)" on mac os x 10.9.2.
    mysql info:
    ps -ef | grep mysql
        0    66     1   0 11:06AM ??         0:00.04 /bin/sh /usr/local/mysql/bin/mysqld_safe --user=mysql
       74   225    66   0 11:06AM ??         0:02.50 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --log-error=/usr/local/mysql/data/Chuans-MacBook-Pro-2.local.err --pid-file=/usr/local/mysql/data/Chuans-MacBook-Pro-2.local.pid --socket=/var/run/mysqld/mysqld.sock
      501   952   947   0  3:52PM ttys000    0:00.00 grep mysql
    Please help!!

    Fascinated and guessing:
    Something related to sock(2) because that's not part of your copied info. I'm thinking you've doubled up on sockets and the second socket doesn't exist, meaning you should be connecting to the first socket "mysqld.sock" whether automatic or not.
    I've only used GUI tools on purpose, so does this mean you've already got MySQL running and you tried to launch it again manually? Perhaps you already have one instance of a db and you're trying to launch a second instance, and the two can't coexist with a single user local db?
    Assuming this is all local, I'd shut down the db service and restart it, out of hand. I've seen similar messages when I set the db to start up on boot, and it didn't finish shutting down when I tried to restart it manually. Usually the GUI won't let me turn it on because it reports it's already running, but in that case it hadn't finished performing what the GUI was reporting.
    Just speculating.

  • MySQL Not Working: Error 2002

    computer:/ javier$ mysql -u root
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2)
    How can I fix this,
    sure enough there is no mysql.sock in that directory

    hey, try this in terminal, creating a symbolic link, from your real socket to a "fake socket"
    sudo ln -s /tmp/mysql.sock /var/mysql/mysql.sock
    Hope this helps!

  • MySQL broken out of the box - error 2002.

    MySQL is broken out of the box - 10.5.2 server. Brand new Xserve, an untouched OS X Server installation, no tinkering was done *at all*.
    Here's what I did:
    1. Opened Server Admin.
    2. Added MySQL service.
    3. Went to Settings.
    4. Changed "Database location" to be on another, faster drive in the Xserve.
    5. Clicked "Start MySQL" button
    6. Opened Terminal, typed in "mysql" and hit Return.
    What do I get?
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2)
    There's no mysql.sock file there, nor in /temp. Running lsof while the mysql daemon is "started up" shows there is a mysql.sock file in /var/mysql though. Very odd.
    Any ideas? I'd like to avoid rolling my own install of MySQL, and stick with the built-in version.

    Might [http://docs.info.apple.com/article.html?artnum=302977|http://docs.info.apple.c om/article.html?artnum=302977] help here? That's for Mac OS X Server Tiger 10.4.4 and not Leopard 10.5 yes, but looks applicable here.
    And FWIW, this basic case is fairly standard MySQL socket behavior on various platforms. That the GUI apparently allowed you to shoot yourself in the foot here is another discussion.

  • MySQL problem -- ERROR 2002 Can't connect to local MySQL server

    Not Sure if this would be a right forum for my problem...
    I'm installing mySQL on my iBook, and thought that I have configured it. But then, after followring some instuctions from Adobe and Marc Liyanage sites, I have a problem to connect. This is what I've done in "TERMINAL"
    ~username$> cd /usr/local/mysql
    mysql ~username$> sudo chown -R mysql data/
    (asking for admin password)
    mysql ~username$> sudo echo
    mysql ~username$> sudo ./bin/mysqld_safe &
    username-ibook-g4:/usr/local/mysql username$ Starting mysqld daemon with databases from /usr/local/mysql/data
    STOPPING server from pid file /usr/local/mysql/data/roshaili-osmans-ibook-g4.local.pid
    060611 16:31:30 mysqld ended
    mysql ~username> /usr/local/mysql/bin/mysql test
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
    [1]+ Done sudo ./bin/mysqld_safe
    mysql ~username>
    When I typed ::
    /usr/local/mysql/bin/mysqladmin -u root
    (see that there's no password)
    Then it displays:
    /usr/local/mysql/bin/mysqladmin Ver 8.41 Distrib 5.0.22, for apple-darwin8.6.0 on powerpc
    Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
    This software comes with ABSOLUTELY NO WARRANTY. This is free software,
    and you are welcome to modify and redistribute it under the GPL license
    Administration program for the mysqld daemon.
    Usage: /usr/local/mysql/bin/mysqladmin [OPTIONS] command command....
    -c, --count=# Number of iterations to make. This works with -i
    (--sleep) only.
    ...... bla bla bla.....
    Variables (--variable-name=value)
    and boolean options {FALSE|TRUE} Value (after reading options)
    count 0
    force FALSE
    compress FALSE
    character-sets-dir (No default value)
    default-character-set (No default value)
    host (No default value)
    port 0
    .........bla bla....
    ping Check if mysqld is alive
    processlist Show list of active threads in server
    reload Reload grant tables
    refresh Flush all tables and close and open logfiles
    shutdown Take server down
    status Gives a short status message from the server
    start-slave Start slave
    stop-slave Stop slave
    variables Prints variables available
    version Get version info from server
    roshaili-osmans-ibook-g4:~ roshailiosman$ >
    -----------------finish-----------------
    Does that mean that I'm connected to mySQL?
    Does anybody how to connect to MYSQL from the terminal? Thanks.
    iMac Mac OS X (10.4.6)
    iMac   Mac OS X (10.4.6)  

    Your biggest 'issue' right now is that your mysqld process is stopping on you -- making a connection impossible.
    Why it's bombing might be in a log .. try in mysql/data/usr.local.err .. and fix why itsbombing.
    To connect to it it'll be : mysql -u root -ppassword -D database

  • Mysql socket error 2002

    I've read all about this error and have played around with it for a while and still can't get it to work. This is how I got to where I am.
    1. installed OS X Server fresh and updated to 10.4.7
    2. installed entrophy php 5.1.4 from the installer pkg
    3. installed mysql standard 5.0.22 from the installer pkg
    4. installed phpMyAdmin and am trying to browse to http://localhost/phpMyAdmin/index.php and am getting the socket error 2002
    I read the technote http://docs.info.apple.com/article.html?artnum=302977 which refers to the mysql.sock file.
    when I start up mysql, it says 'running' and the mysql.sock file is in /var/mysql/ my php.ini file is pointing there. the /etc/my.conf file is pointing there.
    yet I'm still getting this error.
    What am I missing?

    At this point, you have two versions of PHP and two versions of MySQL installed on your system. So, when you say you start up MySQL, how are you doing that?
    For a MySQL-package installed version, you need to start up MySQL in the path /usr/local/mysql/bin/... or use the StartupItem they provide, which would be "/Library/StartupItems/MySQLCOM/MySQLCOM start". Then check where the mysql.sock file is with "/usr/local/mysql/bin/mysqladmin -u root variables" (or "/usr/local/mysql/bin/mysqladmin -u root -p variables", if you've given your root user a password so far).
    Also, you can check your PHP installation's default MySQL socket file search path with "/usr/local/php5/bin/php -i" and see what the "MYSQL_SOCKET" variable states is the location for the MySQL socket file.
    You just have to make sure these two things are in sync in order to get something like phpMyAdmin to run.
    NOTE: If you just type "php" or "mysql" at the command line, you're going to be launching/using Apple's preinstalled versions, so you'll always need to use the full path when working on the command line.

  • ERROR#: 2002 can't connect to MySQL server through socket '/var/mysql/mysql.sock'

    I was following this adobe article (
    http://www.adobe.com/devnet/dreamweaver/articles/php_macintosh.html)
    to set up PHP and MySQL and connect a MySQL database to dreamweaver
    in Mac OS 10.4.8 and I kept getting:
    "Can't connect to MySQL server through socket
    '/var/mysql/mysql.sock' ERROR#: 2002".
    After a lot of searching I came across
    this
    article which said that there was an error in the PHP and MySQL
    connection or something.
    Anyway all I had to do was type (in a TERMINAL window):
    $ sudo mkdir /var/mysql
    $ sudo ln -s /tmp/mysql.sock /var/mysql/mysql.sock
    and that fixed the problem, otherwise the adobe article
    worked very well.
    Check out the "this article" link to get the fix straight
    from the horse's mouth.

    I was following this adobe article (
    http://www.adobe.com/devnet/dreamweaver/articles/php_macintosh.html)
    to set up PHP and MySQL and connect a MySQL database to dreamweaver
    in Mac OS 10.4.8 and I kept getting:
    "Can't connect to MySQL server through socket
    '/var/mysql/mysql.sock' ERROR#: 2002".
    After a lot of searching I came across
    this
    article which said that there was an error in the PHP and MySQL
    connection or something.
    Anyway all I had to do was type (in a TERMINAL window):
    $ sudo mkdir /var/mysql
    $ sudo ln -s /tmp/mysql.sock /var/mysql/mysql.sock
    and that fixed the problem, otherwise the adobe article
    worked very well.
    Check out the "this article" link to get the fix straight
    from the horse's mouth.

  • Php/mySQL error after updating

    I updated my Mac last week from Leopard 10.5.8 to Snow Leopard 10.6.2
    After the update I am now unable to run local connections to the mySQL server I have running on my Mac. I now get this type of error:
    +Warning: mysql_pconnect() [function.mysql-pconnect]: [2002] No such file or directory (trying to connect via unix:///tmp/mysql.sock) in /Users/Luke/Sites/tbec/Connections/tbec.php on line 9+
    +Warning: mysql_pconnect() [function.mysql-pconnect]: No such file or directory in /Users/Luke/Sites/tbec/Connections/tbec.php on line 9+
    +Fatal error: No such file or directory in /Users/Luke/Sites/tbec/Connections/tbec.php on line 9+
    I have checked to see the php.ini file is setup in the etc folder, and it is.
    Has anyone suffered the same issue as me? If so what is the cure?

    Try perusing and posting to the Unix forum under OS X Technologies where those gurus congregate.

Maybe you are looking for