AnsweredAssumed Answered

Load balancer in second node always fails! CacheManager already exists in the same VM.

Question asked by Rodolfo Rodriguez Zavala on Jul 27, 2017
Latest reply on Aug 15, 2017 by Rodolfo Rodriguez Zavala

Hi, I have a question, does anyone knows why when I have installed Adaptive Authentication 7.3 P2 on HA environment  load balancer (Jboss 6.4, Linux 7.2, Java 1.8, Microsoft SQL 2012 R2), when the transaction is going through the first node everything is fine, but when the transacction is going through the second node, it always fails??  

 

The jboss log error is :

 

05:03:22,144 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/AdaptiveAuthentication].[AxisServlet]] (ajp-/0.0.0.0:8009-3) JBWEB000236: Servlet.service() for servlet AxisServlet threw exception: java.lang.reflect.UndeclaredThrowableException
        at com.sun.proxy.$Proxy398.getCallerIps(Unknown Source)
        at com.rsa.csd.servlet.filters.CallerIpFilter.doFilter(CallerIpFilter.java:40) [pmsupport-7.3.0.2.0.jar:7.3.0.2.0]
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:231) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.jboss.modcluster.container.jbossweb.JBossWebContext$RequestListenerValve.event(JBossWebContext.java:91)
        at org.jboss.modcluster.container.jbossweb.JBossWebContext$RequestListenerValve.invoke(JBossWebContext.java:72)
        at org.jboss.as.web.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:134) [jboss-as-web.jar:7.5.15.Final-redhat-3]
        at org.jboss.as.web.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:99) [jboss-as-web.jar:7.5.15.Final-redhat-3]
        at org.jboss.as.web.session.JvmRouteValve.invoke(JvmRouteValve.java:95) [jboss-as-web.jar:7.5.15.Final-redhat-3]
        at org.jboss.as.web.session.LockingValve.invoke(LockingValve.java:64) [jboss-as-web.jar:7.5.15.Final-redhat-3]
        at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50) [jboss-as-jpa.jar:7.5.15.Final-redhat-3]
        at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50) [jboss-as-jpa.jar:7.5.15.Final-redhat-3]
        at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web.jar:7.5.15.Final-redhat-3]
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:151) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.coyote.ajp.AjpAprProcessor.process(AjpAprProcessor.java:475) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.coyote.ajp.AjpAprProtocol$AjpConnectionHandler.process(AjpAprProtocol.java:456) [jbossweb.jar:7.5.22.Final-redhat-1]
        at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:2082) [jbossweb.jar:7.5.22.Final-redhat-1]
        at java.lang.Thread.run(Thread.java:748) [rt.jar:1.8.0_131]
Caused by: com.rsa.csd.config.IGenConfigService$GenConfigException: runtime.ex
        at com.rsa.csd.config.AAOPGenConfigProxyImpl.invoke(AAOPGenConfigProxyImpl.java:126) [rsa-configuration-api-2.6.2.jar:2.6.2]
        at com.rsa.csd.config.GenConfigServiceDynamicProxy.invoke(GenConfigServiceDynamicProxy.java:68) [rsa-configuration-api-2.6.2.jar:2.6.2]
        ... 23 more
Caused by: java.lang.NullPointerException
        at com.rsa.csd.config.GenConfigCommandBase.getRegionContextHeirarchies(GenConfigCommandBase.java:95) [rsa-configuration-api-2.6.2.jar:2.6.2]
        at com.rsa.csd.config.GenConfigGetCommand.handleGet(GenConfigGetCommand.java:241) [rsa-configuration-api-2.6.2.jar:2.6.2]
        at com.rsa.csd.config.GenConfigGetCommand.execute(GenConfigGetCommand.java:55) [rsa-configuration-api-2.6.2.jar:2.6.2]
        at com.rsa.csd.config.AAOPGenConfigProxyImpl.invoke(AAOPGenConfigProxyImpl.java:119) [rsa-configuration-api-2.6.2.jar:2.6.2]
        ... 24 more

 

The aa_server.log error is the follow

 

2017-07-27 10:25:25,965 ERROR [ajp-/0.0.0.0:8009-3] [e6d7-:76041a18d51:c53e78f] [d6d7-:76041a18d51:c53e78f_TRX] [com.rsa.csd.ws.impl.AdaptiveAuthenticationImpl] - <org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'DBLruCacheManager' defined in class path resource [config/cre_beans.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [net.sf.ehcache.CacheManager]: Constructor threw exception; nested exception is net.sf.ehcache.CacheException: Another unnamed CacheManager already exists in the same VM. Please provide unique names for each CacheManager in the config or do one of following:
1. Use one of the CacheManager.create() static factory methods to reuse same CacheManager with same name or create one if necessary
2. Shutdown the earlier cacheManager before creating new one with same name.
The source of the existing CacheManager is: DefaultConfigurationSource [ ehcache.xml or ehcache-failsafe.xml ]>
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'DBLruCacheManager' defined in class path resource [config/cre_beans.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [net.sf.ehcache.CacheManager]: Constructor threw exception; nested exception is net.sf.ehcache.CacheException: Another unnamed CacheManager already exists in the same VM. Please provide unique names for each CacheManager in the config or do one of following:
1. Use one of the CacheManager.create() static factory methods to reuse same CacheManager with same name or create one if necessary
2. Shutdown the earlier cacheManager before creating new one with same name.
The source of the existing CacheManager is: DefaultConfigurationSource [ ehcache.xml or ehcache-failsafe.xml ]
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:1099)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1031)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:504)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)
        at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:303)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
        at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:299)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)
        at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:963)
        at com.rsa.springhelpers.ContextHelper.getBean(ContextHelper.java:34)
        at com.rsa.risk.script.util.CDBLRUCacheLookupAdaptor.refreshCache(CDBLRUCacheLookupAdaptor.java:58)
        at com.rsa.risk.script.util.CDBLRUCacheLookupAdaptor.forcedRefreshedCache(CDBLRUCacheLookupAdaptor.java:70)
        at com.rsa.risk.CRiskEngine.refreshCachedOfflineData(CRiskEngine.java:245)
        at com.rsa.csd.forensic.RiskEngineAnalyzer.refreshOfflineDataCaches(RiskEngineAnalyzer.java:69)
        at com.rsa.csd.forensic.RiskEngineAnalyzer.analyze(RiskEngineAnalyzer.java:31)
        at com.rsa.csd.impl.RsaTransactionImpl.getEventRiskPolicyResult(RsaTransactionImpl.java:1058)
        at com.rsa.csd.impl.RsaTransactionImpl.getEventsRiskPolicyResult(RsaTransactionImpl.java:913)
        at com.rsa.csd.impl.RsaTransactionImpl.analyze(RsaTransactionImpl.java:485)
        at com.rsa.csd.ws.impl.helper.AnalyzeHelper.runRisk(AnalyzeHelper.java:161)
        at com.rsa.csd.ws.impl.AdaptiveAuthenticationImpl.analyze(AdaptiveAuthenticationImpl.java:191)
        at axis.delegate.aa_7_0.AdaptiveAuthenticationDelegate.analyze(AdaptiveAuthenticationDelegate.java:67)
        at com.rsa.csd.ws.axis.generated.AdaptiveAuthenticationSkeleton.analyze(AdaptiveAuthenticationSkeleton.java:81)
        at com.rsa.csd.ws.axis.generated.AdaptiveAuthenticationMessageReceiverInOut.invokeBusinessLogic(AdaptiveAuthenticationMessageReceiverInOut.java:106)
        at org.apache.axis2.receivers.AbstractInOutMessageReceiver.invokeBusinessLogic(AbstractInOutMessageReceiver.java:40)
        at org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:114)
        at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:181)
        at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:172)
        at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:146)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:754)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
        at com.rsa.csd.servlet.filters.SessionCredentialsFilter.doFilter(SessionCredentialsFilter.java:194)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
        at com.rsa.csd.servlet.filters.XsdFilter.doFilter(XsdFilter.java:70)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
        at com.rsa.csd.servlet.filters.CallerIpFilter.doFilter(CallerIpFilter.java:47)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)

        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
        at com.rsa.csd.servlet.filters.XsdFilter.doFilter(XsdFilter.java:70)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
        at com.rsa.csd.servlet.filters.CallerIpFilter.doFilter(CallerIpFilter.java:47)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:231)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149)
        at org.jboss.modcluster.container.jbossweb.JBossWebContext$RequestListenerValve.event(JBossWebContext.java:91)
        at org.jboss.modcluster.container.jbossweb.JBossWebContext$RequestListenerValve.invoke(JBossWebContext.java:72)
        at org.jboss.as.web.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:134)
        at org.jboss.as.web.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:99)
        at org.jboss.as.web.session.JvmRouteValve.invoke(JvmRouteValve.java:95)
        at org.jboss.as.web.session.LockingValve.invoke(LockingValve.java:64)
        at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50)
        at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50)
        at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:151)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
        at org.apache.coyote.ajp.AjpAprProcessor.process(AjpAprProcessor.java:475)
        at org.apache.coyote.ajp.AjpAprProtocol$AjpConnectionHandler.process(AjpAprProtocol.java:456)
        at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:2082)
        at java.lang.Thread.run(Thread.java:748)
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [net.sf.ehcache.CacheManager]: Constructor threw exception; nested exception is net.sf.ehcache.CacheException: Another unnamed CacheManager already exists in the same VM. Please provide unique names for each CacheManager in the config or do one of following:
1. Use one of the CacheManager.create() static factory methods to reuse same CacheManager with same name or create one if necessary
2. Shutdown the earlier cacheManager before creating new one with same name.
The source of the existing CacheManager is: DefaultConfigurationSource [ ehcache.xml or ehcache-failsafe.xml ]
        at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:163)
        at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:89)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:1092)
        ... 59 more
Caused by: net.sf.ehcache.CacheException: Another unnamed CacheManager already exists in the same VM. Please provide unique names for each CacheManager in the config or do one of following:
1. Use one of the CacheManager.create() static factory methods to reuse same CacheManager with same name or create one if necessary
2. Shutdown the earlier cacheManager before creating new one with same name.
The source of the existing CacheManager is: DefaultConfigurationSource [ ehcache.xml or ehcache-failsafe.xml ]
        at net.sf.ehcache.CacheManager.assertNoCacheManagerExistsWithSameName(CacheManager.java:460)
        at net.sf.ehcache.CacheManager.init(CacheManager.java:349)
        at net.sf.ehcache.CacheManager.<init>(CacheManager.java:334)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
        at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:147)
        ... 61 more

 

 

Thanks in advance, 

 

Regards!

Outcomes