jQuery in Action, 3rd edition
The moose likes JDBC and Relational Databases and the fly likes Java MySql connectivity using Linux sockets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Java MySql connectivity using Linux sockets" Watch "Java MySql connectivity using Linux sockets" New topic
Author

Java MySql connectivity using Linux sockets

Mithun Madhu
Greenhorn

Joined: Feb 26, 2009
Posts: 8
Hi,
I had connected my web application developed in Java to MySql using a JDBC driver (mysql-connector-java.jar). It works fine when I connect through TCP/IP using connection string 'jdbc:mysql://127.0.0.1:3306/{database}'.
I tried to connect it through socket after adding 'skip-networking' , 'enable-socket' and 'socket = /var/lib/mysql/mysql.sock' in my.cnf.
When I open MySql through the terminal (mysql -u root -p) it works but my application is unable to connect to MySql using sockets.
Thanks in advance.
 
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: Java MySql connectivity using Linux sockets
 
jQuery in Action, 3rd edition