Can"t connect to mysql server
am 01.05.2006 23:56:40 von dmcquay
Hi,
I am setting up MySQL on a development box. I have set it up and can
connect from localhost, but I cannot connect from another computer on
the network. I have narrowed down the problem quite a bit, but can't
quite figure it out still.
I am getting MySQL Error Number 2003 "Can't connect to MySQL server on
'server'. I know that the server is there because I can ping it. I am
also running a webserver from that computer and I am able to access
that just fine. I know that it is not a rights issue because if you
try to connect with a user that doesn't have rights, MySQL will respond
"Access denied for user: 'user@host' (Using password: YES)".
I checked on the host machine and check that the following are true:
- mysqld.exe is in the process list (in the task manager)
- MySQL is running on port 3306 (the one I'm trying to access it from)
Does anyone have any ideas why I am unable to connect to the MySQL
server?
Re: Can"t connect to mysql server
am 02.05.2006 00:16:07 von Bill Karwin
dmcquay@gmail.com wrote:
> Hi,
>
> I am setting up MySQL on a development box. I have set it up and can
> connect from localhost, but I cannot connect from another computer on
> the network.
It's a typical config for the MySQL installer to enable
"bind-address=127.0.0.1" in the my.ini file. So only clients connecting
from the same host can use MySQL. Comment out that line to disable the
restriction.
This is a dev box, so I assume it's safe from attacks from the internet.
But in general, make sure that disabling the bind-address config
doesn't expose your MySQL instance to connection attempts from the
internet. You'll be hacked within a few minutes.
Regards,
Bill K.
Re: Can"t connect to mysql server
am 10.05.2006 19:18:54 von Bill Karwin
Dustin wrote:
> there is not line containg "bind-address=127.0.0.1" in the my.ini file
> i am using. any other ideas?
The next thing I would check is that you have a firewall preventing you
from reaching port 3306 on the server host. Even while it is allowing
connections on port 80 for your webserver on that machine, a firewall
can block other ports, such as MySQL's 3306.
Regards,
Bill K.