users@glassfish.java.net

Regarding Glassfish Clustering deployment problem

From: Robin G <robin.scar141_at_gmail.com>
Date: Thu, 17 Feb 2011 12:46:16 +0530

Hi,

I am working on Glassfish v2.1.1 server and want to create cluster with
instances running on the same machine.

I have followed below steps to create a cluster.

1) asadmin create-domain --user admin --passwordfile <Appserver
path>/password.txt --adminport 1118 --profile cluster --instanceport 1119
--savemasterpassword=true --domainproperties
jms.port=5860:domain.jmxPort=5862:orb.listener.port=5861:http.ssl.port=5863:orb.ssl.port=5864:orb.mutualauth.port=5865
--savelogin=true --domaindir <Appserver path>/domains clusteredDomain

2) asadmin create-node-agent --host scar.host.name --port 1118 --user
admin --passwordfile <Appserver path>/password.txt --agentdir <Appserver
path>/domains/clusteredDomain/nodeagent --savemasterpassword=true
devNodeAgent

3) asadmin create-cluster --host scar.host.name --port 1118 --user admin
--passwordfile <Appserver path>/password.txt devCluster

4) asadmin create-instance --nodeagent devNodeAgent --host
scar.host.name --port 1118 --user admin --passwordfile <Appserver
path>/password.txt --cluster devCluster --systemproperties
HTTP_LISTENER_PORT=1121:HTTP_SSL_LISTENER_PORT=1122:IIOP_LISTENER_PORT=1123:IIOP_SSL_LISTENER_PORT=1124:IIOP_SSL_MUTUALAUTH_PORT=1125:JMX_SYSTEM_CONNECTOR_PORT=1126
devInstance1

5) asadmin create-instance --nodeagent devNodeAgent --host
scar.host.name --port 1118 --user admin --passwordfile <Appserver
path>/password.txt --cluster devCluster --systemproperties
HTTP_LISTENER_PORT=1131:HTTP_SSL_LISTENER_PORT=1132:IIOP_LISTENER_PORT=1133:IIOP_SSL_LISTENER_PORT=1134:IIOP_SSL_MUTUALAUTH_PORT=1135:JMX_SYSTEM_CONNECTOR_PORT=1136
devInstance2

6) asadmin start-node-agent --user admin --passwordfile <Appserver
path>/password.txt --agentdir <Appserver
path>/domains/clusteredDomain/nodeagent devNodeAgent

7) start-cluster --host scar.host.name --port 1118 --user admin
--passwordfile <Appserver path>/password.txt devCluster

When I deploy an ear file, which is a web service, it got deployed and I
could see it available on all the above 3 HTTP ports i.e. 1119 ,1121, 1131
since I deployed in both server and devCluster as targets.


But when I am trying to hit the service using soapUI, I am getting below
exceptions

Note: working fine on port 1119.

*Reponse from service deployed in the Cluster (ports 1121 , 1131)::::*

<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
   <env:Body>
      <env:Fault>
         <faultcode>env:Server</faultcode>
         <faultstring>JAXRPCSERVLET30: Internal server error
(JAXRPCSERVLET43: failed to instantiate service implementor for port
"ExecutePortType")</faultstring>
      </env:Fault>
   </env:Body>
</env:Envelope>

In logs i can see that :

[#|2011-02-17T00:20:02.755-0600|INFO|sun-appserver2.1|javax.enterprise.system.container.ejb|_ThreadID=20;_ThreadName=httpSSLWorkerThread-1131-0;|EJB5070:
Exce
ption creating stateless session bean : [{0}]
javax.ejb.CreateException: could not create CMap1_jcdClusterSvc1
        at
prjCluster.CMap1_jcdClusterSvc1.jcdClusterSvc_Runtime_Handler.ejbCreate(prjCluster.CMap1_jcdClusterSvc1.jcdClusterSvc_Runtime_Handler:562)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessor


[#|2011-02-17T00:20:02.758-0600|FINE|sun-appserver2.1|javax.enterprise.system.container.ejb|_ThreadID=20;_ThreadName=httpSSLWorkerThread-1131-0;ClassName=com.
sun.ejb.containers.BaseContainer;MethodName=preInvoke;_RequestID=894b24b4-e986-45e1-94cd-4586ac7ab0af;|
javax.ejb.EJBException: nested exception is: javax.ejb.EJBException: nested
exception is: javax.ejb.CreateException: Could not create stateless EJB
javax.ejb.EJBException: nested exception is: javax.ejb.CreateException:
Could not create stateless EJB
javax.ejb.CreateException: Could not create stateless EJB
        at
com.sun.ejb.containers.StatelessSessionContainer.createStatelessEJB(StatelessSessionContainer.java:579)
        at
com.sun.ejb.containers.StatelessSessionContainer.access$100(StatelessSessionContainer.java:111)
        at
com.sun.ejb.containers.StatelessSessionContainer$SessionContextFactory.create(StatelessSessionContainer.java:783)
        at
com.sun.ejb.containers.util.pool.NonBlockingPool.getObject(NonBlockingPool.java:199)
        at
com.sun.ejb.containers.StatelessSessionContainer._getContext(StatelessSessionContainer.java:489)
        at
com.sun.ejb.containers.BaseContainer.getContext(BaseContainer.java:1709)
        at
com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:1238)
        at
com.sun.ejb.containers.EJBLocalObjectInvocationHandler.invoke(EJBLocalObjectInvocationHandler.java:195)
        at
com.sun.ejb.containers.EJBLocalObjectInvocationHandler.invoke(EJBLocalObjectInvocationHandler.java:134)

Could you please tell me do I need to install any other components into my
cluster?

It would be really helpfull for me.

Thanks in advance :)

Regards,
Robin