Juan Luis Prieto Martínez wrote:
> Hi all,
>
> This is my first post in this mailing list. I write because I am
> having an issue starting a domain after importing some p12
> certificates and it is something quite urgent.
>
> I have installed glassfish 2.1 in a virtual machine with java 1.6, I
> have deployed a couple of war files and I am able to see the wsdl of
> the webservice within them. After that I do an import of a couple of
> certificates that I have to install to interact with another component
> that I need. The import is correct, doesn't fail and I also change the
> name of the keystores and the keystores password.
You cannot change the keystore password independent of the glassfish
master password. If you need to change the keystore password then make
sure it first matches the glassfish master password and then change the
master password to what you want the new keystore password be.
http://weblogs.java.net/blog/kumarjayanti/archive/2007/11/index.html#4
regards,
kumar
>
> Now the problem comes when I stop de domain and I try to start it
> afterwards. In the console I get a time out exception and in the
> server.log the exception I can see is this.
>
> 23-Jun-2009 11:56:02
> com.sun.enterprise.admin.servermgmt.launch.ASLauncher buildCommand
> INFO:
> C:/Program Files/Java/jdk1.6.0_14/jre/..\bin\java
> -Dcom.sun.aas.instanceRoot=C:/utils/glassfish/domains/pdp
> -Dcom.sun.aas.ClassPathPrefix=
> -Dcom.sun.aas.ClassPathSuffix=
> -Dcom.sun.aas.ServerClassPath=
> -Dcom.sun.aas.classloader.appserverChainJars.ee
> <http://Dcom.sun.aas.classloader.appserverChainJars.ee>=
> -Dcom.sun.aas.classloader.appserverChainJars=admin-cli.jar,admin-cli-ee.jar,j2ee-svc.jar
> -Dcom.sun.aas.classloader.excludesList=admin-cli.jar,appserv-upgrade.jar,sun-appserv-ant.jar
> -Dcom.sun.aas.classloader.optionalOverrideableChain.ee
> <http://Dcom.sun.aas.classloader.optionalOverrideableChain.ee>=
> -Dcom.sun.aas.classloader.optionalOverrideableChain=webservices-rt.jar,webservices-tools.jar
> -Dcom.sun.aas.classloader.serverClassPath.ee
> <http://Dcom.sun.aas.classloader.serverClassPath.ee>=/lib/hadbjdbc4.jar,C:/utils/glassfish/lib/SUNWjdmk/5.1/lib/jdmkrt.jar,/lib/dbstate.jar,/lib/hadbm.jar,/lib/hadbmgt.jar,/lib/mfwk_instrum_tk.jar
> -Dcom.sun.aas.classloader.serverClassPath=C:/utils/glassfish/lib/install/applications/jmsra/imqjmsra.jar,C:/utils/glassfish/imq/lib/jaxm-api.jar,C:/utils/glassfish/imq/lib/fscontext.jar,C:/utils/glassfish/imq/lib/imqbroker.jar,C:/utils/glassfish/imq/lib/imqjmx.jar,C:/utils/glassfish/lib/ant/lib/ant.jar,C:/utils/glassfish/lib/SUNWjdmk/5.1/lib/jdmkrt.jar
> -Dcom.sun.aas.classloader.sharedChainJars.ee
> <http://Dcom.sun.aas.classloader.sharedChainJars.ee>=appserv-se.jar,appserv-ee.jar,jesmf-plugin.jar,/lib/dbstate.jar,/lib/hadbjdbc4.jar,jgroups-all.jar,/lib/mfwk_instrum_tk.jar
> -Dcom.sun.aas.classloader.sharedChainJars=javaee.jar,C:/Program
> Files/Java/jdk1.6.0_14/jre/../lib/tools.jar,install/applications/jmsra/imqjmsra.jar,com-sun-commons-launcher.jar,com-sun-commons-logging.jar,C:/utils/glassfish/imq/lib/jaxm-api.jar,C:/utils/glassfish/imq/lib/fscontext.jar,C:/utils/glassfish/imq/lib/imqbroker.jar,C:/utils/glassfish/imq/lib/imqjmx.jar,C:/utils/glassfish/imq/lib/imqxm.jar,webservices-rt.jar,webservices-tools.jar,mail.jar,appserv-jstl.jar,jmxremote_optional.jar,C:/utils/glassfish/lib/SUNWjdmk/5.1/lib/jdmkrt.jar,activation.jar,appserv-rt.jar,appserv-admin.jar,appserv-cmp.jar,C:/utils/glassfish/updatecenter/lib/updatecenter.jar,C:/utils/glassfish/jbi/lib/jbi.jar,C:/utils/glassfish/imq/lib/imqjmx.jar,C:/utils/glassfish/lib/ant/lib/ant.jar,dbschema.jar
> -Dcom.sun.aas.configName=server-config
> -Dcom.sun.aas.configRoot=C:/utils/glassfish/config
> -Dcom.sun.aas.defaultLogFile=C:/utils/glassfish/domains/pdp/logs/server.log
> -Dcom.sun.aas.domainName=pdp
> -Dcom.sun.aas.installRoot=C:/utils/glassfish
> -Dcom.sun.aas.instanceName=server
> -Dcom.sun.aas.processLauncher=SE
> -Dcom.sun.aas.promptForIdentity=true
> -Dcom.sun.enterprise.config.config_environment_factory_class=com.sun.enterprise.config.serverbeans.AppserverConfigEnvironmentFactory
> -Dcom.sun.enterprise.overrideablejavaxpackages=javax.help,javax.portlet
> -Dcom.sun.enterprise.taglibs=appserv-jstl.jar,jsf-impl.jar
> -Dcom.sun.enterprise.taglisteners=jsf-impl.jar
> -Dcom.sun.updatecenter.home=C:/utils/glassfish/updatecenter
> -Ddomain.name=pdp
> -Djava.endorsed.dirs=C:/utils/glassfish/lib/endorsed
> -Djava.ext.dirs=C:/Program
> Files/Java/jdk1.6.0_14/jre/../lib/ext;C:/Program
> Files/Java/jdk1.6.0_14/jre/../jre/lib/ext;C:/utils/glassfish/domains/pdp/lib/ext;C:/utils/glassfish/javadb/lib
> -Djava.library.path=C:\utils\glassfish\lib;C:\utils\glassfish\lib;C:\utils\glassfish\bin;C:\utils\glassfish\lib
> -Djava.security.auth.login.config=C:/utils/glassfish/domains/pdp/config/login.conf
> -Djava.security.policy=C:/utils/glassfish/domains/pdp/config/server.policy
> -Djava.util.logging.manager=com.sun.enterprise.server.logging.ServerLogManager
> -Djavax.management.builder.initial=com.sun.enterprise.admin.server.core.jmx.AppServerMBeanServerBuilder
> -Djavax.net.ssl.keyStore=C:/utils/glassfish/domains/pdp/config/keystore.jks
> -Djavax.net.ssl.trustStore=C:/utils/glassfish/domains/pdp/config/cacerts.jks
> -Djdbc.drivers=org.apache.derby.jdbc.ClientDriver
> -Djmx.invoke.getters=true
> -Dsun.rmi.dgc.client.gcInterval=3600000
> -Dsun.rmi.dgc.server.gcInterval=3600000
> -client
> -XX:+UnlockDiagnosticVMOptions
> -XX:MaxPermSize=192m
> -Xmx512m
> -XX:NewRatio=2
> -XX:+LogVMOutput
> -XX:LogFile=C:/utils/glassfish/domains/pdp/logs/jvm.log
> -cp
> C:/utils/glassfish/lib/jhall.jar;C:\utils\glassfish\lib\appserv-launch.jar
> com.sun.enterprise.server.PELaunch
> start
> [#|2009-06-23T11:56:03.453+0100|INFO|sun-appserver2.1|javax.enterprise.system.core|_ThreadID=10;_ThreadName=main;Java
> HotSpot(TM) Client VM;1.6.0_14;Sun Microsystems Inc.;|CORE5076: Using
> [Java HotSpot(TM) Client VM, Version 1.6.0_14] from [Sun Microsystems
> Inc.]|#]
>
> [#|2009-06-23T11:56:03.500+0100|INFO|sun-appserver2.1|javax.enterprise.system.core.security|_ThreadID=11;_ThreadName=pool-1-thread-2;|SEC1002:
> Security Manager is OFF.|#]
>
> [#|2009-06-23T11:56:03.656+0100|INFO|sun-appserver2.1|javax.enterprise.resource.jms|_ThreadID=12;_ThreadName=pool-1-thread-5;|Using
> MQ RA for Broker lifecycle control|#]
>
> [#|2009-06-23T11:56:05.406+0100|WARNING|sun-appserver2.1|javax.enterprise.system.stream.err|_ThreadID=10;_ThreadName=main;_RequestID=dd1ef5d2-24df-4452-ab9e-af6e779d5e9a;|java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:597)
> at com.sun.enterprise.server.PELaunch.main(PELaunch.java:415)
> Caused by: java.lang.ExceptionInInitializerError
> at
> com.sun.enterprise.security.SecurityLifecycle.onInitialization(SecurityLifecycle.java:101)
> at
> com.sun.enterprise.server.ApplicationServer.onInitialization(ApplicationServer.java:262)
> at
> com.sun.enterprise.server.ondemand.OnDemandServer.onInitialization(OnDemandServer.java:103)
> at com.sun.enterprise.server.PEMain.run(PEMain.java:399)
> at com.sun.enterprise.server.PEMain.main(PEMain.java:336)
> ... 5 more
> Caused by: java.lang.IllegalStateException:
> java.security.UnrecoverableKeyException: Cannot recover key
> at com.sun.enterprise.security.SSLUtils.<clinit>(SSLUtils.java:128)
> ... 10 more
> Caused by: java.security.UnrecoverableKeyException: Cannot recover key
> at sun.security.provider.KeyProtector.recover(KeyProtector.java:311)
> at
> sun.security.provider.JavaKeyStore.engineGetKey(JavaKeyStore.java:121)
> at
> sun.security.provider.JavaKeyStore$JKS.engineGetKey(JavaKeyStore.java:38)
> at java.security.KeyStore.getKey(KeyStore.java:763)
> at
> com.sun.net.ssl.internal.ssl.SunX509KeyManagerImpl.<init>(SunX509KeyManagerImpl.java:113)
> at
> com.sun.net.ssl.internal.ssl.KeyManagerFactoryImpl$SunX509.engineInit(KeyManagerFactoryImpl.java:48)
> at javax.net.ssl.KeyManagerFactory.init(KeyManagerFactory.java:239)
> at
> com.sun.enterprise.security.SSLUtils.initKeyManagers(SSLUtils.java:320)
> at com.sun.enterprise.security.SSLUtils.<clinit>(SSLUtils.java:106)
> ... 10 more
> |#]
>
>
> Any idea what can it be the problem.
>
> Thanks for your help
>
> JuanLu
>
>
> --
> JuanLu