Ok, I finally solved the problem.
I had to place the MySQL driver into app server
classpath.
The thing is that, when trying to deploy my app, I was
first receiving this error message:
Internal Exception: java.sql.SQLException: Error in
allocating a connection. Cause: Class name is wrong or
classpath is not set for :
com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSourceError
Code: 0
, but then I would try to deploy again and then the
driver exception would not appear, but only the
persistence unit problem, so I thought the driver
problem was gone.
Please excuse my lack of experience.
Thank you all very much for your help !
Ivan
--- Mitesh Meswani <Mitesh.Meswani_at_Sun.COM> wrote:
> Hi Ivan,
>
> As Tom already pointed out, you would get into the
> situation if
> something went wrong at deployment time. It is
> strange that there are no
> exceptions in the log at deployment time. I can see
> that you are running
> with JDK 6. Can you you try switching to JDK 5? In
> any case, would it be
> possible for you to attach your netbeans project?
> That might help one of
> us to take a closer look at the situation.
>
> Thanks,
> Mitesh
>
> Ivan Matavulj wrote:
> > Hello Tom, thanks a lot for your reply.
> > I will post the server startup log & bean
> deployment
> > log here, maybe something can be figured out from
> it.
> > Server startup log:
> >
> > C:/Program Files/Java/jdk1.6.0\bin\java
> > -client
> > -Xmx512m
> > -XX:NewRatio=2
> >
>
-Dcom.sun.aas.defaultLogFile=C:/SunAppServer/domains/domain1/logs/server.log
> > -Djava.endorsed.dirs=C:/SunAppServer/lib/endorsed
> >
>
-Djava.security.policy=C:/SunAppServer/domains/domain1/config/server.policy
> >
>
-Djava.security.auth.login.config=C:/SunAppServer/domains/domain1/config/login.conf
> > -Dsun.rmi.dgc.server.gcInterval=3600000
> > -Dsun.rmi.dgc.client.gcInterval=3600000
> >
>
-Djavax.net.ssl.keyStore=C:/SunAppServer/domains/domain1/config/keystore.jks
> >
>
-Djavax.net.ssl.trustStore=C:/SunAppServer/domains/domain1/config/cacerts.jks
> > -Djava.ext.dirs=C:/Program
> >
>
Files/Java/jdk1.6.0/jre/lib/ext;C:/SunAppServer/domains/domain1/lib/ext;C:/SunAppServer/javadb/lib
> > -Djdbc.drivers=org.apache.derby.jdbc.ClientDriver
> >
>
-Djavax.management.builder.initial=com.sun.enterprise.admin.server.core.jmx.AppServerMBeanServerBuilder
> >
>
-Dcom.sun.enterprise.config.config_environment_factory_class=com.sun.enterprise.config.serverbeans.AppserverConfigEnvironmentFactory
> >
>
-Dcom.sun.enterprise.taglibs=appserv-jstl.jar,jsf-impl.jar
> > -Dcom.sun.enterprise.taglisteners=jsf-impl.jar
> >
>
-Dcom.sun.aas.classloader.optionalOverrideableChain=appserv-ws.jar,commons-logging.jar,commons-launcher.jar
> >
>
-Dcom.sun.aas.classloader.appserverChainJars=admin-cli.jar,admin-cli-ee.jar,dbschema.jar,j2ee-svc.jar
> >
>
-Dcom.sun.aas.classloader.serverClassPath.ee=%HADB_HOME%/lib/hadbjdbc4.jar,C:/SunAppServer/lib/SUNWjdmk/5.1/lib/jdmkrt.jar,%HADB_HOME%/lib/dbstate.jar,%HADB_HOME%/lib/hadbm.jar,%HADB_HOME%/lib/hadbmgt.jar,C:/SunAppServer/lib/SUNWmfwk/lib/mfwk_instrum_tk.jar
> > -Dcom.sun.aas.configName=server-config
> > -Ddomain.name=domain1
> > -Djmx.invoke.getters=true
> > -Dcom.sun.aas.promptForIdentity=true
> >
>
-Dcom.sun.aas.classloader.optionalOverrideableChain.ee=
> >
>
-Dcom.sun.aas.instanceRoot=C:/SunAppServer/domains/domain1
> > -Dcom.sun.aas.domainName=domain1
> >
>
-Dcom.sun.aas.classloader.sharedChainJars=javaee.jar,C:/Program
> >
>
Files/Java/jdk1.6.0/lib/tools.jar,install/applications/jmsra/imqjmsra.jar,commons-launcher.jar,C:/SunAppServer/imq/lib/jaxm-api.jar,C:/SunAppServer/imq/lib/fscontext.jar,C:/SunAppServer/imq/lib/imqbroker.jar,C:/SunAppServer/imq/lib/imqjmx.jar,C:/SunAppServer/imq/lib/imqxm.jar,C:/SunAppServer/lib/ant/lib/ant.jar,appserv-ws.jar,mail.jar,jsf-api.jar,jsf-impl.jar,appserv-jstl.jar,appserv-env.jar,jmxremote_optional.jar,C:/SunAppServer/lib/SUNWjdmk/5.1/lib/jdmkrt.jar,commons-logging.jar,activation.jar,appserv-rt.jar,appserv-admin.jar,appserv-cmp.jar
> >
>
-Dcom.sun.aas.classloader.sharedChainJars.ee=appserv-se.jar,appserv-ee.jar,%HADB_HOME%/lib/dbstate.jar,%HADB_HOME%/lib/hadbjdbc4.jar,jgroups-all.jar,C:/SunAppServer/lib/SUNWmfwk/lib/mfwk_instrum_tk.jar
> >
>
-Djava.util.logging.manager=com.sun.enterprise.server.logging.ServerLogManager
> >
>
-Dcom.sun.enterprise.overrideablejavaxpackages=javax.xml.bind,javax.help,javax.portlet
> >
>
-Dcom.sun.aas.classloader.serverClassPath=C:/SunAppServer/lib/install/applications/jmsra/imqjmsra.jar,C:/SunAppServer/imq/lib/jaxm-api.jar,C:/SunAppServer/imq/lib/fscontext.jar,C:/SunAppServer/imq/lib/imqbroker.jar,C:/SunAppServer/imq/lib/imqjmx.jar,C:/SunAppServer/lib/ant/lib/ant.jar,C:/SunAppServer/lib/SUNWjdmk/5.1/lib/jdmkrt.jar
> > -Dcom.sun.aas.classloader.appserverChainJars.ee=
> > -Dcom.sun.aas.configRoot=C:/SunAppServer/config
> >
>
-Djava.library.path=C:\SunAppServer\lib;C:\SunAppServer\lib;C:\Program
> >
>
Files\Java\jdk1.6.0\bin;.;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\SunAppServer\lib;C:\SunAppServer\bin;C:\SunAppServer\bin;C:\SunAppServer\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program
> > Files\Java\jdk1.6.0\bin;C:\mysql50\bin;C:\Program
> >
>
Files\QuickTime\QTSystem\;C:\SunAppServer\bin;C:\Sun\AppServer\bin
> > -Dcom.sun.aas.instanceName=server
> > -Dcom.sun.aas.processLauncher=SE
> > -Dcom.sun.aas.installRoot=C:/SunAppServer
> > -Dcom.sun.aas.ClassPathPrefix=
> > -Dcom.sun.aas.ClassPathSuffix=
> > -Dcom.sun.aas.ServerClassPath=
> > -cp
> > ;C:/SunAppServer/lib/appserv-launch.jar
> > com.sun.enterprise.server.PELaunch
> > start
> > Starting Sun Java System Application Server
> Platform
> > Edition 9.0_01 (build b02-p01) ...
> > CORE5098: AS Socket Service Initialization has
> been
> > completed.
> > CORE5076: Using [Java HotSpot(TM) Client VM,
> Version
> > 1.6.0] from [Sun Microsystems Inc.]
> > SEC1002: Security Manager is OFF.
> > ADM0001:MBeanServer initialized successfully
> > SEC1143: Loading policy provider
> >
> com.sun.enterprise.security.provider.PolicyWrapper.
> > sgmt.service_initialized
> > DPL5400:Exception occurred : error in opening zip
> > file.
> > ADM1079: Initialization of AMX MBeans successful
> > ADM1504: Here is the JMXServiceURL for the
> Standard
> > JMXConnectorServer:
> > [service:jmx:rmi:///jndi/rmi://vito:8686/jmxrmi].
> > This is where the remote administrative clients
> should
> > connect using the standard JMX connectors
> > ADM1506: Status of Standard JMX Connector: Active
> =
> > [true]
> > SMGT0007: Self Management Rules service is enabled
> > Application server startup complete.
> > WEB0302: Starting
> Sun-Java-System/Application-Server.
> > WEB0100: Loading web module [__default-admingui]
> in
> > virtual server [__asadmin] at [/]
> > WEB0100: Loading web module [adminapp] in virtual
> > server [__asadmin] at [/web1]
> > WEB0100: Loading web module [admingui] in virtual
> > server [__asadmin] at [/asadmin]
> > Initializing Sun's JavaServer Faces implementation
> > (1.2_02-b03-FCS) for context ''
> > Completed initializing Sun's JavaServer Faces
> > implementation (1.2_02-b03-FCS) for context ''
> > Initializing Sun's JavaServer Faces implementation
> > (1.2_02-b03-FCS) for context '/asadmin'
> > Completed initializing Sun's JavaServer Faces
> > implementation (1.2_02-b03-FCS) for context
> '/asadmin'
> > WEB0712: Starting
> Sun-Java-System/Application-Server
> > HTTP/1.1 on 8080
> > WEB0712: Starting
> Sun-Java-System/Application-Server
> > HTTP/1.1 on 8181
> > WEB0712: Starting
> Sun-Java-System/Application-Server
> > HTTP/1.1 on 4848
> > About to load the system app: __JWSappclients
> > WEB0100: Loading web module
> [__JWSappclients:sys.war]
> > in virtual server [server] at [/__JWSappclients]
> >
> >
> >
> > EJB DEPLOYMENT LOG:
> >
> > ADM1064:The upload file at [C:\Documents and
> > Settings\Cyvan\Local
> >
>
Settings\Temp\s1astempdomain1server-1647709010\TestEJB.jar]
> > exists and will be overwritten.
> > ADM1006:Uploading the file to:[C:\Documents and
> > Settings\Cyvan\Local
> >
>
Settings\Temp\s1astempdomain1server-1647709010\TestEJB.jar]
> > deployed with moduleid = TestEJB
> > ADM1041:Sent the event to
> instance:[ModuleDeployEvent
> > -- enable ejb/TestEJB]
> > [TopLink Config]: 2007.02.15
> > 12:49:09.890--ServerSession(1615774)--The alias
> name
> > for the entity class [class server.Linija] is
> being
> > defaulted to: Linija.
> > naming.bind
> > **RemoteBusinessJndiName: HandlerALRemote;
> > remoteBusIntf: server.HandlerALRemote
> > naming.bind
> > LDR5010: All ejb(s) of [TestEJB] loaded
> successfully!
> >
> >
> > Thanks,
> > Ivan
> >
> > --- Tom Ware <tom.ware_at_oracle.com> wrote:
> >
> >
> >> Hi Ivan,
> >>
> >> I am not a Sun AS Expert, so maybe someone with
>
=== message truncated ===
____________________________________________________________________________________
Need a quick answer? Get one in minutes from people who know.
Ask your question on www.Answers.yahoo.com