tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shiv Kumar MN" <shivkumar...@majoris.com>
Subject In memory session replication
Date Wed, 19 Jun 2002 06:13:32 GMT
Hello,

I am trying to setup Tomcat clustering to achieve:
    1. Load balancing
    2. Fail over

I am referring to Fillip's article on this on "www.theserverside.com"
and Pascal Forget's article on "www.ubeans.com". I am having some
problem in getting it work. Could any one please help me on this?

What I have done:

1. I followed what Pascal Forget article says, also I have verified
    after these steps that Tomcat/Apache is really doing load balancing.
    This part of it is working fine.
2. Now I followed the steps indicated in Fillip's article to integrate
   Fillip's method and Pascal Forget's method so that I get load balancing
   as well as fail over without loosing session.

    After following the steps and restarting Tomcat-1, Tomcat-2 followed
    by Apache, I see some error logs in both Tomcat's "logs" directory, log
    file "localhost_log.2002-06-15.txt". The error is:

    java.lang.NullPointerException at
org.apache.catalina.session.InMemoryReplicationManager.createSession(InMemoryReplicationManager.java:212)

    I have attached this log file at the end of this mail for your reference.
    Please let me know where I am going wrong.

Setup Environment:

Tomcat-1:
Linux v6.2, JDK 1.4 (J2SE), Tomcat v4.0.3

Tomcat-2:
Solaris v2.7 SPARC Ent 450 server, JDK 1.4 (J2SE), Tomcat v4.0.3

Apache:
Linux v6.2, mod_jk, Apache v1.3.24

Thank you for your help and time,

Best Regards,
 - Shiv.

Following is the localhost_log.YYYY-MM-DD file:

2002-06-15 16:20:31 WebappLoader[/manager]: Deploying class repositories to work
directory /apps/jakarta-tomcat-4.0.3/work/localhost/manager
2002-06-15 16:20:31 StandardManager[/manager]: Seeding random number generator
class java.security.SecureRandom
2002-06-15 16:20:31 StandardManager[/manager]: Seeding of random number
generator has been completed
2002-06-15 16:20:32 ContextConfig[/manager]: Added certificates -> request
attribute Valve
2002-06-15 16:20:32 ContextConfig[/manager]: Configured an authenticator for
method BASIC
2002-06-15 16:20:32 StandardWrapper[/manager:default]: Loading container servlet
default
2002-06-15 16:20:32 default: init
2002-06-15 16:20:32 StandardWrapper[/manager:invoker]: Loading container servlet
invoker
2002-06-15 16:20:32 invoker: init
2002-06-15 16:20:32 jsp: init
2002-06-15 16:20:32 WebappLoader[/inko]: Deploying class repositories to work
directory /apps/jakarta-tomcat-4.0.3/work/localhost/inko
2002-06-15 16:20:32 WebappLoader[/inko]: Reloading checks are enabled for this
Context
2002-06-15 16:20:33 ContextConfig[/inko]: Added certificates -> request
attribute Valve
2002-06-15 16:20:33 StandardWrapper[/inko:default]: Loading container servlet
default
2002-06-15 16:20:33 default: init
2002-06-15 16:20:33 StandardWrapper[/inko:invoker]: Loading container servlet
invoker
2002-06-15 16:20:33 invoker: init
2002-06-15 16:20:33 jsp: init
2002-06-15 16:20:35 StandardHost[localhost]: Installing web application at
context path /tomcat-docs from URL
file:/apps/jakarta-tomcat-4.0.3/webapps/tomcat-docs
2002-06-15 16:20:35 WebappLoader[/tomcat-docs]: Deploying class repositories to
work directory /apps/jakarta-tomcat-4.0.3/work/localhost/tomcat-docs
2002-06-15 16:20:35 StandardManager[/tomcat-docs]: Seeding random number
generator class java.security.SecureRandom
2002-06-15 16:20:35 StandardManager[/tomcat-docs]: Seeding of random number
generator has been completed
2002-06-15 16:20:35 ContextConfig[/tomcat-docs]: Added certificates -> request
attribute Valve
2002-06-15 16:20:35 StandardWrapper[/tomcat-docs:default]: Loading container
servlet default
2002-06-15 16:20:35 default: init
2002-06-15 16:20:35 StandardWrapper[/tomcat-docs:invoker]: Loading container
servlet invoker
2002-06-15 16:20:35 invoker: init
2002-06-15 16:20:35 jsp: init
2002-06-15 16:20:35 StandardHost[localhost]: Installing web application at
context path /webdav from URL file:/apps/jakarta-tomcat-4.0.3/webapps/webdav
2002-06-15 16:20:35 WebappLoader[/webdav]: Deploying class repositories to work
directory /apps/jakarta-tomcat-4.0.3/work/localhost/webdav
2002-06-15 16:20:35 StandardManager[/webdav]: Seeding random number generator
class java.security.SecureRandom
2002-06-15 16:20:35 StandardManager[/webdav]: Seeding of random number generator
has been completed
2002-06-15 16:20:35 ContextConfig[/webdav]: Added certificates -> request
attribute Valve
2002-06-15 16:20:35 StandardWrapper[/webdav:default]: Loading container servlet
default
2002-06-15 16:20:35 default: init
2002-06-15 16:20:35 StandardWrapper[/webdav:invoker]: Loading container servlet
invoker
2002-06-15 16:20:35 invoker: init
2002-06-15 16:20:35 jsp: init
2002-06-15 16:20:35 StandardHost[localhost]: Installing web application at
context path /RT from URL file:/apps/jakarta-tomcat-4.0.3/webapps/RT
2002-06-15 16:20:35 WebappLoader[/RT]: Deploying class repositories to work
directory /apps/jakarta-tomcat-4.0.3/work/localhost/RT
2002-06-15 16:20:35 StandardManager[/RT]: Seeding random number generator class
java.security.SecureRandom
2002-06-15 16:20:35 StandardManager[/RT]: Seeding of random number generator has
been completed
2002-06-15 16:20:36 ContextConfig[/RT]: Added certificates -> request attribute
Valve
2002-06-15 16:20:36 StandardWrapper[/RT:default]: Loading container servlet
default
2002-06-15 16:20:36 default: init
2002-06-15 16:20:36 StandardWrapper[/RT:invoker]: Loading container servlet
invoker
2002-06-15 16:20:36 invoker: init
2002-06-15 16:20:36 jsp: init
2002-06-15 16:21:59 jsp: init
2002-06-15 16:21:59 JspFactoryImpl: Exception initializing page context
java.lang.NullPointerException
	at
org.apache.catalina.session.InMemoryReplicationManager.createSession(InMemoryReplicationManager.java:212)
	at
org.apache.catalina.session.InMemoryReplicationManager.createSession(InMemoryReplicationManager.java:242)
	at
org.apache.catalina.connector.HttpRequestBase.doGetSession(HttpRequestBase.java:1108)
	at
org.apache.catalina.connector.HttpRequestBase.getSession(HttpRequestBase.java:1064)
	at
org.apache.catalina.connector.HttpRequestFacade.getSession(HttpRequestFacade.java:209)
	at
org.apache.catalina.connector.HttpRequestFacade.getSession(HttpRequestFacade.java:218)
	at
org.apache.jasper.runtime.PageContextImpl._initialize(PageContextImpl.java:138)
	at
org.apache.jasper.runtime.PageContextImpl.initialize(PageContextImpl.java:114)
	at
org.apache.jasper.runtime.JspFactoryImpl.internalGetPageContext(JspFactoryImpl.java:175)
	at
org.apache.jasper.runtime.JspFactoryImpl.getPageContext(JspFactoryImpl.java:154)
	at org.apache.jsp.index$jsp._jspService(index$jsp.java:45)
	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
	at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:202)
	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:382)
	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2343)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at org.apache.ajp.tomcat4.Ajp13Processor.process(Ajp13Processor.java:429)
	at org.apache.ajp.tomcat4.Ajp13Processor.run(Ajp13Processor.java:495)
	at java.lang.Thread.run(Thread.java:536)

--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message