R: R: How to start Connector/MXJ ?
"tech" <[email protected]>
| Newsgroups | gmane.comp.db.mysql.java |
|---|---|
| Organization | edoss consulenze |
| Message-ID | <[email protected]> |
Here attached you can find my console output. Cheers, Roberto Regazzoni -----Messaggio originale----- Da: Eric Herman [mailto:[email protected]] Inviato: lunedì 18 settembre 2006 15.42 A: tech Cc: [email protected] Oggetto: Re: R: How to start Connector/MXJ ? Hello Roberto Regazzoni, On Mon, 2006-09-18 at 14:52 +0200, tech wrote: > Yes, Eric. Both files are in the CLASSPATH environment variable as follows: > > C:\connector-mxj\connector-mxj\connector-mxj.jar;C:\connector-mxj\connector- > mxj\lib\aspectjrt.jar > > Please note that the first directory called connector-mxj includes two > directories: > 1) connector-mxj > 2) META-INF > > > As I read at the end of paragraph 23.4.3.1 of the online manual ( > http://dev.mysql.com/doc/refman/5.0/en/connector-mxj-configuration-driver-la > unched.html ) I also tried to add to the CLASSPATH the Connector/J as > follows: > > C:\Programmi\MySQL\mysql-connector-java-5.0.3\mysql-connector-java-5.0.3-bin > .jar > > but I still get the previous errors. Okay, so far that all sounds right. Can you please try again and record the entire console output, including the display of the classpath? I've attached an example of the what I'm looking for generated from my Windows XP SP2 machine. > > > Please note that the path to MySQL Server is not in the CLASSPATH, but in > the Path environment variable, as follows: > C:\Programmi\MySQL\MySQL Server 5.0\bin For the record, that should not make a difference what other MySQL servers you have installed because Connector/MXJ uses its own "mysqld-nt.exe" for launching the mysql server. Cheers, - Eric > > > My setup is the following: > Windows XP Service Pack 2 > Java 1.5.0_06 > MySQL 5.0.24a > Connector/J 5.0.3 > Connector/MXJ 5.0.3 beta > > > I'm open to any suggestion, even to go back to previous releases of MySQL, > Connector/J, Connector/MXJ. > > Thanks in advance > > Roberto Regazzoni > > > > > -----Messaggio originale----- > Da: Eric Herman [mailto:[email protected]] > Inviato: lunedì 18 settembre 2006 13.22 > A: tech > Cc: [email protected] > Oggetto: Re: How to start Connector/MXJ ? > > Hello Roberto Regazzoni, > > On Mon, 2006-09-18 at 11:21 +0200, tech wrote: > > I developed a simple java application based on MySQL 5.0.24a and > > Connector/J 5.0.3. It works. > > > > I read I could deploy such an application to other clients by means of > > Connector/MXJ. > > > > I downloaded Connector/MXJ 5.0.3 beta on my development pc and tried to > > install it following the online manual step by step. > > > > > > > > Following chapter 23.4.2.3 Connector/MXJ Quick Start Guide, > > > http://dev.mysql.com/doc/refman/5.0/en/connector-mxj-install-quickstart.html > > > > > > > > > > I tried to run ConnectorMXJUrlTestExample. Unfortunately I got the > following > > messages: > > > > 1) Mysqld is not running > > > > 2) There is no file MysqldResource.pid > > > > 3) Could not create socket factory > > 'com.mysql.management.driverlaunched.ServerLauncherSocketFactory' because > > the class was not found. > > > > > > > > Can anyone give me some help ? > > Sure. I'd be glad to try to help. > > On the surface it looks like a classpath issue. > > What the CLASSPATH set to? > Is connector-mxj.jar in classpath? > What about aspectjrt.jar (found in the connector-mxj "lib" directory)? > > Cheers, > -Eric > > > > > > > > > Thanks in advance > > > > Roberto Regazzoni > > > > > > > > > > > > > > > > > > > > > > > > Below you can see the error log: > > > > > > > > > > > > > jdbc:mysql:mxj://localhost:3336/test?server.basedir=C:\DOCUME~1\Roberto\IMPO > > ST~1\Temp\test-mxj > > > > [MysqldResource] Mysqld not running. No file: C:\Documents and > > Settings\Roberto\Impostazioni locali\Temp\test-mxj\data\MysqldResource.pid > > > > Exception in thread "main" > > com.mysql.jdbc.exceptions.MySQLNonTransientConnectionException: Could not > > create socket factory > > 'com.mysql.management.driverlaunched.ServerLauncherSocketFactory' due to > > underlying exception: java.lang.ClassNotFoundException: > > com.mysql.management.driverlaunched.ServerLauncherSocketFactory > > > > > > > > ** BEGIN NESTED EXCEPTION ** > > > > > > > > java.lang.ClassNotFoundException > > > > MESSAGE: com.mysql.management.driverlaunched.ServerLauncherSocketFactory > > > > > > > > STACKTRACE: > > > > > > > > java.lang.ClassNotFoundException: > > com.mysql.management.driverlaunched.ServerLauncherSocketFactory > > > > at java.net.URLClassLoader$1.run(Unknown Source) > > > > at java.security.AccessController.doPrivileged(Native Method) > > > > at java.net.URLClassLoader.findClass(Unknown Source) > > > > at java.lang.ClassLoader.loadClass(Unknown Source) > > > > at java.lang.ClassLoader.loadClass(Unknown Source) > > > > at java.lang.ClassLoader.loadClassInternal(Unknown Source) > > > > at java.lang.Class.forName0(Native Method) > > > > at java.lang.Class.forName(Unknown Source) > > > > at com.mysql.jdbc.MysqlIO.createSocketFactory(MysqlIO.java:2167) > > > > at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:274) > > > > at com.mysql.jdbc.Connection.createNewIO(Connection.java:2641) > > > > at com.mysql.jdbc.Connection.<init>(Connection.java:1531) > > > > at > > com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266) > > > > at java.sql.DriverManager.getConnection(Unknown Source) > > > > at java.sql.DriverManager.getConnection(Unknown Source) > > > > at > > ConnectorMXJUrlTestExample.main(ConnectorMXJUrlTestExample.java:30) > > > > > > > > > > > > ** END NESTED EXCEPTION ** > > > > > > > > > > > > at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:888) > > > > at com.mysql.jdbc.MysqlIO.createSocketFactory(MysqlIO.java:2170) > > > > at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:274) > > > > at com.mysql.jdbc.Connection.createNewIO(Connection.java:2641) > > > > at com.mysql.jdbc.Connection.<init>(Connection.java:1531) > > > > at > > com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266) > > > > at java.sql.DriverManager.getConnection(Unknown Source) > > > > at java.sql.DriverManager.getConnection(Unknown Source) > > > > at > > ConnectorMXJUrlTestExample.main(ConnectorMXJUrlTestExample.java:30) > > > > > > > > > > > > > > > > > > __________ Informazione NOD32 1.1760 (20060918) __________ Questo messaggio è stato controllato dal Sistema Antivirus NOD32 http://www.nod32.it -- MySQL Java Mailing List For list archives: http://lists.mysql.com/java To unsubscribe: http://lists.mysql.com/[email protected]
RobertoRegazzoni_Console_output.txt
(text/plain, 3.1 KB)
C:\Documents and Settings\Roberto\IBM\rationalsdp6.0\XML\TextMXJ>java -version
java version "1.5.0_06"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-b05)
Java HotSpot(TM) Client VM (build 1.5.0_06-b05, mixed mode)
C:\Documents and Settings\Roberto\IBM\rationalsdp6.0\XML\TextMXJ>SET CLASSPATH
CLASSPATH=.;C:\PROGRA~1\IBM\SQLLIB\java\db2java.zip;C:\PROGRA~1\IBM\SQLLIB\java\db2jcc.jar;C:\PROGRA~1\IBM\SQLLIB\java\sqlj.zip;C:\PROGRA~1\IBM\SQLLIB\java\db2jcc_license_cu.jar;C:\PROGRA~1\IBM\SQLLIB\bin;C:\PROGRA~1\IBM\
ector-mxj\connector-mxj\lib\aspectjrt.jar;C:\Programmi\MySQL\mysql-connector-java-5.0.3\mysql-connector-java-5.0.3-bin.jar
C:\Documents and Settings\Roberto\IBM\rationalsdp6.0\XML\TextMXJ>java ConnectorMXJUrlTestExample
jdbc:mysql:mxj://localhost:3336/test?server.basedir=C:\DOCUME~1\Roberto\IMPOST~1\Temp\test-mxj
[MysqldResource] Mysqld not running. No file: C:\Documents and Settings\Roberto\Impostazioni locali\Temp\test-mxj\data\MysqldResource.pid
Exception in thread "main" com.mysql.jdbc.exceptions.MySQLNonTransientConnectionException: Could not create socket factory 'com.mysql.management.driverlaunched.ServerLauncherSocketFactory' due to underlying exception: jav
erSocketFactory
** BEGIN NESTED EXCEPTION **
java.lang.ClassNotFoundException
MESSAGE: com.mysql.management.driverlaunched.ServerLauncherSocketFactory
STACKTRACE:
java.lang.ClassNotFoundException: com.mysql.management.driverlaunched.ServerLauncherSocketFactory
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at com.mysql.jdbc.MysqlIO.createSocketFactory(MysqlIO.java:2167)
at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:274)
at com.mysql.jdbc.Connection.createNewIO(Connection.java:2641)
at com.mysql.jdbc.Connection.<init>(Connection.java:1531)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266)
at java.sql.DriverManager.getConnection(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at ConnectorMXJUrlTestExample.main(ConnectorMXJUrlTestExample.java:30)
** END NESTED EXCEPTION **
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:888)
at com.mysql.jdbc.MysqlIO.createSocketFactory(MysqlIO.java:2170)
at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:274)
at com.mysql.jdbc.Connection.createNewIO(Connection.java:2641)
at com.mysql.jdbc.Connection.<init>(Connection.java:1531)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266)
at java.sql.DriverManager.getConnection(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at ConnectorMXJUrlTestExample.main(ConnectorMXJUrlTestExample.java:30)