Mod_Cluster /context root mapping issue in JBOSS EAP 6.2 with httpd Apache Webserver
sridhar_a.r Aug 25, 2014 11:31 AMHi Friends,
1) I have two Jboss EAP 6.2 domain ( say Domain A & Domain B) working in cluster mode.
Domain A : Architecture is as below
Host X Host Y
Node 1 Node2
An Application with context root "/checkin" is deployed in this Domain A
Domain B : Architecture is as below
Host X Host Y
Node 3 Node4
An Application with context root "/checkout" is deployed in this Domain B
2) I have used two httpd apache webserver ( say integration.com & acceptance.com ) :
Application with content root /checkin is hosted via mod_cluster configurartion in integration.com ( www.integation.com/checkin )
Application with content root /checkout is hosted via mod_cluster configurartion in acceptance.com ( www.acceptance.com/checkout )
3)My integation Webserver Configuration is as below:
+++++++++++++++++++++++++++++++++++++++++
Listen 10.9.8.27:8777
<VirtualHost 10.9.8.27:80>
<Directory />
Order Allow,Deny
Allow from all
</Directory>
<Location /mc>
SetHandler mod_cluster-manager
Order Allow,Deny
Allow from all
</Location>
</VirtualHost>
<VirtualHost 10.9.8.27:8777>
<Directory />
Order Allow,Deny
Allow from all
</Directory>
ServerAdvertise on http://10.9.8.27:8777
AdvertiseGroup 224.0.1.105:8662
</VirtualHost>
8777 - Virtual port used in Webserver
8662 - Multicast port used in domain.xml of domain A
Entry in domain.xml of domain A
<socket-binding name="modcluster" port="0" multicast-address="224.0.1.105" multicast-port="8662"/>
4)My Acceptance Webserver Configuration is as below:
+++++++++++++++++++++++++++++++++++++++++
Listen 10.9.8.23:7777
<VirtualHost 10.9.8.23:80>
<Directory />
Order Allow,Deny
Allow from all
</Directory>
<Location /mc>
SetHandler mod_cluster-manager
Order Allow,Deny
Allow from all
</Location>
</VirtualHost>
<VirtualHost 10.9.8.23:7777>
<Directory />
Order Allow,Deny
Allow from all
</Directory>
ServerAdvertise on http://10.9.8.23:7777
AdvertiseGroup 224.0.1.105:8682
</VirtualHost>
7777 - Virtual port used in Webserver
8682 - Multicast port used in domain.xml of domain B
Entry in domain.xml of domain B :
<socket-binding name="modcluster" port="0" multicast-address="224.0.1.105" multicast-port="8682"/>
5) My Mod_cluster management console output for integraton Webserver is as follows:
http://www-integration.com/mc/
Node: [1],Name: 44d049b3-f395-3f4b-9ab5-74659b8d84e7,Balancer: mycluster,LBGroup: ,Host: Host A,Port: 8653,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 0,Read: 0,Transfered: 0,Connected: 0,Load: 100
Node: [2],Name: 0e77b697-4484-30f4-a2f8-2c85bcc0b01b,Balancer: mycluster,LBGroup: ,Host: Host B,Port: 8653,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 0,Read: 0,Transfered: 0,Connected: 0,Load: 100
Node: [3],Name: 78d8593e-3799-3bb1-ba06-548b10b69f17,Balancer: mycluster,LBGroup: ,Host: Host B,Port: 8673,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 240,Read: 1090516,Transfered: 0,Connected: 0,Load: 100
Node: [4],Name: fcb7b94f-ab52-33ff-adae-366767025cb7,Balancer: mycluster,LBGroup: ,Host: Host A,Port: 8673,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 8,Read: 423273,Transfered: 0,Connected: 0,Load: 100
Vhost: [1:1:1], Alias: default-host
Vhost: [1:1:2], Alias: localhost
Vhost: [1:1:3], Alias: example.com
Vhost: [2:1:4], Alias: default-host
Vhost: [2:1:5], Alias: localhost
Vhost: [2:1:6], Alias: example.com
Vhost: [3:1:7], Alias: default-host
Vhost: [3:1:8], Alias: localhost
Vhost: [3:1:9], Alias: example.com
Vhost: [4:1:10], Alias: default-host
Vhost: [4:1:11], Alias: localhost
Vhost: [4:1:12], Alias: example.com
Context: [1:1:1], Context: /checkin, Status: ENABLED
Context: [2:1:2], Context: /checkin, Status: ENABLED
Context: [3:1:3], Context: /checkout, Status: ENABLED
Context: [4:1:4], Context: /checkout, Status: ENABLED
6) My Mod_cluster management console output for Acceptance Webserver is as follows:
Node: [1],Name: 44d049b3-f395-3f4b-9ab5-74659b8d84e7,Balancer: mycluster,LBGroup: ,Host: Host A,Port: 8653,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 0,Read: 0,Transfered: 0,Connected: 0,Load: 100
Node: [2],Name: 0e77b697-4484-30f4-a2f8-2c85bcc0b01b,Balancer: mycluster,LBGroup: ,Host: Host B,Port: 8653,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 0,Read: 0,Transfered: 0,Connected: 0,Load: 100
Node: [3],Name: 78d8593e-3799-3bb1-ba06-548b10b69f17,Balancer: mycluster,LBGroup: ,Host: Host B,Port: 8673,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 240,Read: 1090516,Transfered: 0,Connected: 0,Load: 100
Node: [4],Name: fcb7b94f-ab52-33ff-adae-366767025cb7,Balancer: mycluster,LBGroup: ,Host: Host A,Port: 8673,Type: ajp,Flushpackets: Off,Flushwait: 10,Ping: 10,Smax: 26,Ttl: 60,Elected: 8,Read: 423273,Transfered: 0,Connected: 0,Load: 100
Vhost: [1:1:1], Alias: default-host
Vhost: [1:1:2], Alias: localhost
Vhost: [1:1:3], Alias: example.com
Vhost: [2:1:4], Alias: default-host
Vhost: [2:1:5], Alias: localhost
Vhost: [2:1:6], Alias: example.com
Vhost: [3:1:7], Alias: default-host
Vhost: [3:1:8], Alias: localhost
Vhost: [3:1:9], Alias: example.com
Vhost: [4:1:10], Alias: default-host
Vhost: [4:1:11], Alias: localhost
Vhost: [4:1:12], Alias: example.com
Context: [1:1:1], Context: /checkin, Status: ENABLED
Context: [2:1:2], Context: /checkin, Status: ENABLED
Context: [3:1:3], Context: /checkout, Status: ENABLED
Context: [4:1:4], Context: /checkout, Status: ENABLED
7) Issue statement :
All 4 Nodes are visible to both the webservers ( integration & acceptance) so content root /checkin & /checkout are accessible from both the webservers but
I need /checkin to be accessible only from www.integration.com and /checkout to be accessible only from www.acceptance.com
i.e.
I need only Node1 and Node2 to Listen to proxy advertisements on 224.0.1.105:8662
&
I need only Node3 and Node4 to Listen to proxy advertisements on 224.0.1.105:8682
Kindly let me know how I can instruct the worker nodes(Node 1 & Node2) to join only a specified <multicast_addr:port> and also instruct worker nodes(Node 3 & Node 4) to join <some_other_multicast_addr:some_other_port>
Thanks in Advance
Regards
Sridhar