mysql cannot connect

Temmu

Well-known member
Joined
Apr 18, 2012
Posts
436
Location
far reaches of the galaxy, but you knew that...
can anyone resolve this? please?
yes, the service is running.
Yes, 3307 is the port.
Yes, MySQL51 service is started. the workbench shows "running"

i can start a session from start, all programs, mysql, mysql server5.1, command line session,
that produces this:
Code:
Enter password: ****
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 10
Server version: 5.1.70-community-log MySQL Community Server (GPL)


Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.


Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.


Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.


mysql>

but, when i try to run a command line from c:\> i cannot.
yes, i added the path system variable, c:\...\bin\

Code:
C:\>mysql
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)
Code:
C:\>mysql -u root -p
Enter password: ****
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)

Code:
C:\>mysql -u root -proot
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)

Code:
C:\>mysql -u root -p root
Enter password: ****
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)

Code:
C:\>mysql -u root -p sakila
Enter password: ****
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)

Code:
C:\>mysql -u root -p sakila_full
Enter password: ****
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)

Code:
C:\>telnet localhost 3307

(screen clears then:)
B
 5.1.70-community-log   MMz?jw:W!☻+mg<6:]G,DQL☺♦Got packets out of order


Connection to host lost.
 
Hi,

Try logging in like this.

Code:
 shell > C:\Program Files\MySQL\MySQL Server 5.1\bin\mysql -u root -p

That should work. I don't believe that you can just type C:\msyql like you can in linux, unix, or mac.
 
Ignore this...just noticed your original post


Make sure the service is still there in Control panel > Admin tools > Services (or local services)

There were a few versions a while back that had an exploit that would let an attacker remove the service.

The service name is something like "mysql" or "mysql database"
 
Are you trying to run mysql as a service by itself, or are you running it in a program like xampp?
 

Has Sysnative Forums helped you? Please consider donating to help us support the site!

Back
Top