Jump to content


Photo

Connecting to a remote mysql server


  • Please log in to reply
4 replies to this topic

#1 alexis101

alexis101
  • Members
  • Pip
  • Newbie
  • 4 posts

Posted 05 March 2006 - 08:43 PM

Hello everyone,
My problem is:
I have a remote mysql server and i cant connect to it . I granted all privilege to root from my ip address (i have a static one) and still when i try to conect to my server i still have the message
ERROR 2003 (HY000): Can't connect to MySQL server on (XXX.XXX.XXX.XXX)

Here is what i did :
mysql>GRANT ALL PRIVILEGES ON *.* TO root@XXX.XXX.XXX.XXX IDENTIFIED BY "**********";
and on my local machine
localhost ~ # mysql --host=XXX.XXX.XXX.XXX --pass
Enter password:
ERROR 2003 (HY000): Can't connect to MySQL server on 'XXX.XXX.XXX.XXX' (111)


Anyone can point me where i did my error?
Thank you!

#2 wickning1

wickning1
  • Members
  • PipPipPip
  • Advanced Member
  • 405 posts

Posted 05 March 2006 - 10:21 PM

Is it firewalled?

#3 alexis101

alexis101
  • Members
  • Pip
  • Newbie
  • 4 posts

Posted 06 March 2006 - 07:35 PM

no

#4 wickning1

wickning1
  • Members
  • PipPipPip
  • Advanced Member
  • 405 posts

Posted 06 March 2006 - 07:47 PM

There's nothing wrong from a MySQL standpoint, it has to be some kind of networking error. My best guess is that the server is not listening to the default port (3306 I believe), or there is a firewall somewhere in between.

#5 alexis101

alexis101
  • Members
  • Pip
  • Newbie
  • 4 posts

Posted 06 March 2006 - 08:44 PM

well i did a ngrep on the port 3306 and here is what i got :
ngrep -W byline 3306
interface: eth0 (XXX.XXX.XXX.XXX/XXX.XXX.XXX.XXX)
match: 3306
#########################################################################
#########################################################################
#########################################################################
#########################################################################
#########################################################################
#########################################################################
#########################################################################
exit
98549 received, 0 dropped
localhost ~ #

Anyway i dont understand my server is not behind any firewall or any router ...




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users