List:General Discussion« Previous MessageNext Message »
From:SGreen Date:December 2 2005 9:43pm
Subject:Re: can't connect to the MySQL server from remote machine?
View as plain text  
That means that the MySQL server installed on the machine on which you 
issued the command is running AND that it can be connected to by the local 
loopback address (127.0.0.1). This still does not mean that you can 
connect to it from any other machine as your firewall may permit local 
(within the machine) communication but still block access from all other 
addresses.

If your server is on a different machine, substitute 127.0.0.1 with the 
actual address or DNS name of the machine you are trying to connect to 
("localhost"  CANNOT be it unless the server is on the same machine you 
are).

Shawn Green
Database Administrator
Unimin Corporation - Spruce Pine

Jenny Chen <luojiac@stripped> wrote on 12/02/2005 04:28:51 PM:

> Hi,
> 
> I tried with
> "telnet localhost 3306"
> locally, and got the message as:
> 
> "Connected to localhost.localdomain (127.0.0.1).
> Escape character is '^]'.
> =
> 5.0.16-standard!QS//?.e,7~9>iw;]E!r=Connection closed by foreign host."
> 
> What is this meaning?
> 
> Thanks,
> Jenny
> 
> On 12/2/05, Fernando Antunes <fs.antunes@stripped> wrote:
> >
> > To test if the 3306 is listening, try this command from client :
> >
> > telnet hostname 3306
> >
> > If MySQL return some string, it´s there and listening
> > If not, two possibilities :
> >
> >   1) A firewall between or on client and server
> >   2) MYSQL is stopped or listening in a different port.
> >
> > What is the version of your MYSQL ?
> >
> >
> > On 12/2/05, Jenny Chen <luojiac@stripped> wrote:
> > >
> > > Yes, I did try both hostname and IP, but can't work although I can 
ping
> > > to
> > > the two boxes from each other.
> > > Just wondering if it is because of the port(3306) got disabled??
> > >
> > >
> > > Thanks,
> > > Jenny
> > >
> > >
> > >
> > >
> > > On 12/2/05, SGreen@stripped <SGreen@stripped> wrote:
> > > >
> > > >
> > > >
> > > > Jenny Chen < luojiac@stripped> wrote on 12/02/2005 12:27:33
> PM:
> > > >
> > > > > Hi,
> > > > >
> > > > > I'm trying to connect to the MySQL server on the RedHat AS 4 
from a
> > > > remote
> > > > > Solaris SPARC box. When I run the command:
> > > > >
> > > > > mysql -h HOSTNAME
> > > > >
> > > > > I got the error as
> > > > >
> > > > > ERROR 2003 (HY000): Can't connect to MySQL server on 'HOSTNAME'
> > > (145)
> > > > >
> > > > >
> > > > >
> > > > > Could anyone please explain what the mean of the error message 
and
> > > how
> > > > to
> > > > > solve it?
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > Thanks,
> > > > >
> > > > > Jenny
> > > >
> > > > The value after the -h must either be a valid hostname in your
> > > > organization or an IP address. If you can "ping" the server you 
want
> > > to
> > > > reach by name, that's the name to use. Otherwize use the IP 
address of
> > > the
> > > > machine you are trying to reach.
> > > >
> > > > Shawn Green
> > > > Database Administrator
> > > > Unimin Corporation - Spruce Pine
> > >
> > >
> >

Thread
can't connect to the MySQL server from remote machine?Jenny Chen2 Dec
  • Re: can't connect to the MySQL server from remote machine?SGreen2 Dec
    • Re: can't connect to the MySQL server from remote machine?Jenny Chen2 Dec
Re: can't connect to the MySQL server from remote machine?Jenny Chen2 Dec
  • Re: can't connect to the MySQL server from remote machine?SGreen2 Dec