我对JBoss有点新鲜,请你帮我解决下面提到的问题的根本原因。谢谢,非常感谢,
问题:主服务器(域名)之间没有发生会话复制 控制器)和从属(主机)。以下是日志,
来自大师:
[Server:server-three] 07:53:38,246 INFO [org.infinispan.remoting.transport.jgroups.JGroupsTransport] (ServerService Thread Pool -- 65) ISPN000078: Starting JGroups Channel
[Server:server-three] 07:53:38,260 INFO [stdout] (ServerService Thread Pool -- 65)
[Server:server-three] 07:53:38,260 INFO [stdout] (ServerService Thread Pool -- 65) -------------------------------------------------------------------
[Server:server-three] 07:53:38,261 INFO [stdout] (ServerService Thread Pool -- 65) GMS: address=master:server-three/web, cluster=web, physical address=10.78.216.145:7850
[Server:server-three] 07:53:38,261 INFO [stdout] (ServerService Thread Pool -- 65) -------------------------------------------------------------------
[Host Controller] 07:53:40,511 INFO [org.jboss.as.domain] (Host Controller Service Threads - 25) JBAS010918: Registered remote slave host "slave", JBoss EAP 6.3.0.GA (AS 7.4.0.Final-redhat-19)
[Server:server-three] 07:53:41,273 INFO [org.infinispan.remoting.transport.jgroups.JGroupsTransport] (ServerService Thread Pool -- 65) ISPN000094: Received new cluster view: [master:server-three/web|0] [master:server-three/web]
[Server:server-three] 07:53:41,275 INFO [org.infinispan.remoting.transport.jgroups.JGroupsTransport] (ServerService Thread Pool -- 65) ISPN000079: Cache local address is master:server-three/web, physical addresses are [10.78.216.145:7850]
[Server:server-three] 07:53:41,279 INFO [org.infinispan.factories.GlobalComponentRegistry] (ServerService Thread Pool -- 65) ISPN000128: Infinispan version: Infinispan 'Delirium' 5.2.10.Final
[Server:server-three] 07:53:41,288 INFO [org.jboss.as.clustering] (MSC service thread 1-6) JBAS010238: Number of cluster members: 1
来自奴隶:
[Server:server-three-slave] 07:53:36,274 INFO [org.infinispan.remoting.transport.jgroups.JGroupsTransport] (ServerService Thread Pool -- 67) ISPN000078: Starting JGroups Channel
[Server:server-three-slave] 07:53:36,287 INFO [stdout] (ServerService Thread Pool -- 67)
[Server:server-three-slave] 07:53:36,287 INFO [stdout] (ServerService Thread Pool -- 67) -------------------------------------------------------------------
[Server:server-three-slave] 07:53:36,288 INFO [stdout] (ServerService Thread Pool -- 67) GMS: address=slave:server-three-slave/web, cluster=web, physical address=10.78.216.36:7850
[Server:server-three-slave] 07:53:36,288 INFO [stdout] (ServerService Thread Pool -- 67) -------------------------------------------------------------------
[Server:server-three-slave] 07:53:39,301 INFO [org.infinispan.remoting.transport.jgroups.JGroupsTransport] (ServerService Thread Pool -- 67) ISPN000094: Received new cluster view: [slave:server-three-slave/web|0] [slave:server-three-slave/web]
[Server:server-three-slave] 07:53:39,302 INFO [org.infinispan.remoting.transport.jgroups.JGroupsTransport] (ServerService Thread Pool -- 67) ISPN000079: Cache local address is slave:server-three-slave/web, physical addresses are [10.78.216.36:7850]
[Server:server-three-slave] 07:53:39,306 INFO [org.infinispan.factories.GlobalComponentRegistry] (ServerService Thread Pool -- 67) ISPN000128: Infinispan version: Infinispan 'Delirium' 5.2.10.Final
[Server:server-three-slave] 07:53:39,315 INFO [org.jboss.as.clustering] (MSC service thread 1-5) JBAS010238: Number of cluster members: 1
我正在宣传我的群集,我可以看到UI中存在主节点和从节点,
https://10.78.X.X:8445/mod_cluster_manager
,
我已禁用防火墙和SELinux以避免网络问题。我相信,我已经在httpd的domain.xml
和ssl.conf
中完成了所有必需的配置。我在战争中也添加了<distributable/>
代码和jboss-web.xml
更改。如果你们中的任何人指导我朝着不同的方向前进,那将会更有帮助,因为我完全迷失了,
即使我在主日志中也能看到以下内容:
[Host Controller] 07:18:58,862 INFO [org.jboss.as.domain] (Host Controller Service Threads - 28) JBAS010918: Registered remote slave host "slave", JBoss EAP 6.3.0.GA (AS 7.4.0.Final-redhat-19)
[Server:server-three] 07:18:59,029 INFO [org.infinispan.remoting.transport.jgroups.JGroupsTransport] (ServerService Thread Pool -- 69) ISPN000094: Received new cluster view: [master:server-three/web|0] [master:server-three/web]
我尝试使用stickySession添加ProxyPass,运气不好。任何建议或帮助将不胜感激,
谢谢, 喜悦。
答案 0 :(得分:0)
必须将<distributable/>
标记添加到web.xml
jboss-web.xml
文件中
在您的应用中启用会话复制
<强>概述强>
利用JBoss企业应用平台的高可用性(HA)&gt;功能,配置您的应用程序 可分发的。此过程说明了如何执行此操作,然后 解释了您可以使用的一些高级配置选项。
- 必填:表明您的应用程序是可分发的。
醇>如果您的应用程序未标记为可分发,则其会话将会 永远不会分发。在里面添加
<distributable />
元素 您的应用程序<web-app>
描述符文件的web.xml
标记。这里 就是一个例子。<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4"> <distributable/> </web-app>