If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > MySQL > MySQL connection

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-03-07, 11:09
krReddy krReddy is offline
Registered User
 
Join Date: Oct 2006
Posts: 83
Thumbs up MySQL connection

I have installed MySQL in my machine which is in LINUX .
I am able to connect to MySQL from command line in my machine .

When i tried to connect MySQL from any other applications like DataStudio,DBVisualizer etc it is throwing the following error

java.net.SocketException
MESSAGE: java.net.ConnectException: Connection refused

PHP Code:
STACKTRACE:

java.net.SocketExceptionjava.net.ConnectExceptionConnection refused
        at com
.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:156)
        
at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:284)
        
at com.mysql.jdbc.Connection.createNewIO(Connection.java:2555)
        
at com.mysql.jdbc.Connection.<init>(Connection.java:1485)
        
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266)
        
at java.sql.DriverManager.getConnection(DriverManager.java:582)
        
at java.sql.DriverManager.getConnection(DriverManager.java:154)
        
at NMFL.zk.e(Unknown Source
I have disabled the firewall in my machine by stopping the IPTABLES using command
/etc/init.d/iptables stop

Kindly suggest me what to do
Reply With Quote
  #2 (permalink)  
Old 07-03-07, 11:17
krReddy krReddy is offline
Registered User
 
Join Date: Oct 2006
Posts: 83
Some more Info..

When i telnet to the MySQL (telnet localhost 3306)port the below error is thrown
Quote:
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
telnet: Unable to connect to remote host: Connection refused
Reply With Quote
  #3 (permalink)  
Old 07-04-07, 01:44
swapnilclarion swapnilclarion is offline
Registered User
 
Join Date: May 2007
Posts: 8
Hi,

Please check configuration file My.cnf, if you have skip_networking in it.
Also check for current user privileges or create new user with all privileges.

Thanks,
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On