This content has been marked as final.
Show 3 replies
-
1. Re: Database Connection Problem
peterj May 17, 2008 2:40 PM (in response to badhikary81)Please post the following items:
The *-ds.xml file for you datasource.
The stack trace for the excpetion you are getting.The code used to access the database. -
2. Re: Database Connection Problem
badhikary81 May 19, 2008 6:24 AM (in response to badhikary81)"PeterJ" wrote:
Please post the following items:
The *-ds.xml file for you datasource.
The stack trace for the excpetion you are getting.The code used to access the database.
Thanks for reply.
Here is the main problem that I am not able to connect remote server database which is created by Mysql.that's why I am not able to create CMP Entity Bean for Database.
When I trying to connect remote server database using Netbean IDE. THEN connection is faild.I am using Host name: IP Address Or 192.168.1.101 and
Port:3306 ,DB:Remote server Database. UserName and Password of remote server mysql database.
When I used Host Name:192.168.1.101 then following Stacktrace Exception arise
java.net.ConnectException: Connection time out:connect
at java.net.PlainSocketImpl.socketConnect(Native Method )
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at java.net.Socket.connect(Socket.java:519)
at java.net.Socket.connect(Socket.java:469)
at java.net.Socket.(Socket.java:366)
at java.net.Socket.(Socket.java:209)
at com.mysql.jdbc.StandardSocketFactory.Connect(StandardSocketFactory.java:256)
at com.mysql.jdbc.MysqlIO.(MysqlIO.java:271)
at com.mysql.jdbc.Connection.createNewIO(Connection.java:2771)
at com.mysql.jdbc.Connection.(Connectio.java:1555)
at com.mysql.jdbc.NonRegisteringDriver.Connect(NonRegisteringDriver.java:285)
at org.netbeans.modules.db.explorer.DbDriverManager.getConnection(DbDriverManager.java:122)
org.netbeans.modules.db.explorer..DatabaseConnection s2.run(DatabaseConnection.java:533)
at org.openide.util.RequestPeocessorS Task.run(RequestProcessor.java:561)
when I used HostName:IP Address then following exception arise
Unable to add COnnection:
jdbc:mysql://IP Address:3306/db:name using mysql.jdbc.Driver(Access denied for us
er 'cityslikkers'@'122.167.240.76'(using password:YES))
Please help me how to solve this problem.I need your help sir.
thanks and regards
raj -
3. Re: Database Connection Problem
peterj May 19, 2008 11:36 AM (in response to badhikary81)Sorry, but I cannot help you with NetBeans (this is the JBossAS forum, after all, not the NetBeans forum). But it does look like the password is incorrect.
If you need JBossAS help with connection to MySQL, then provide the information I asked for earlier. And the stack trace should come from the JBossAS console log.