-
1. Re: Can't serve multiple contexts
jfclere Aug 24, 2016 8:59 AM (in response to jplorier)not sure I get what you are trying to do...
Basically mod_cluster_manager should display the aliases and context if you don't see what you expect it won't work.
Additionally EAP 6.3.4 is old, can't you use a newer version?
-
2. Re: Can't serve multiple contexts
jplorier Aug 24, 2016 10:37 AM (in response to jfclere)Hi,
First, sorry for my mistake, it's eap 6.4.3.
I can see the contexts I expect to see in the manager. I also see that the aliases are incorrect and can't find where it's getting them.
I have two apps, broker and storedprox. Each in a different server group, broker on port 8080 with alias prep.hg.sucive.gub.uy and showing that alias and broker in the manager, storedproc on port 8180 with alias stored.prep.hg.sucive.gub.uy and showing in the manager the same alias that broker (which is wrong).
I checked that server alias is right for both virtual servers in EAP and in neither case, there's a broker alias defined.
If I point to prep.hg.sucive.gub.uy, I should be answered by the default virtual server, but I'm getting apache test page. If I add either context, I get a 404 (prep.hg.sucive.gub.uy/broker or prep.hg.sucive.gub.uy/storedproc)
If you need me to clarify further, please let me know.
Regards
-
3. Re: Can't serve multiple contexts
jfclere Aug 25, 2016 4:31 AM (in response to jplorier)you need to define the
virtual-server with its aliases in the web subsystem and use the same
virtual-server
injboss-web.xml of the web-app.
-
4. Re: Can't serve multiple contexts
jplorier Aug 29, 2016 4:21 PM (in response to jfclere)Hi,
Sorry for the late reply but I had to ask the dev team to change the jboss-web.xml. They added the tag <virtual-host>broker</virtual-host> to the file. The result is the same. This is the output of the modcluster_manager:
mod_cluster/2.0.0.Alpha1-SNAPSHOT
start of "httpd.conf" configuration
mod_proxy_cluster.c: OK
mod_sharedmem.c: OK
Protocol supported: http AJP
mod_advertise.c: OK
Server: lb01.prep.sucive.gub.uy
Server: lb01.prep.sucive.gub.uy VirtualHost: 192.168.110.10:8000 Advertising on Group 224.0.1.105 Port 23364 for http://192.168.110.10:8000 every 10 seconds
end of "httpd.conf" configuration
Auto Refresh show DUMP output show INFO output
Node b681457d-af17-3564-87af-de21e6dd9531 (http://192.168.120.51:8180):
Enable Contexts Disable Contexts Stop Contexts
Balancer: brokerPREP,LBGroup: ,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 2,Ttl: 60000000,Status: OK,Elected: 0,Read: 0,Transferred: 0,Connected: 0,Load: 100
Virtual Host 1:
Contexts:
/storedproc, Status: ENABLED Request: 0 Disable Stop
Aliases:
broker prep.hg.sucive.gub.uy
Node cab8314f-e5c4-3e73-8df7-80ce23f982b0 (http://192.168.120.50:8080):
Enable Contexts Disable Contexts Stop Contexts
Balancer: brokerPREP,LBGroup: ,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 2,Ttl: 60000000,Status: OK,Elected: 0,Read: 0,Transferred: 0,Connected: 0,Load: 100
Virtual Host 1:
Contexts:
/broker, Status: ENABLED Request: 0 Disable Stop
Aliases:
prep.hg.sucive.gub.uy broker
Node 2f6cc401-32c3-325f-858c-560c0d735517 (http://192.168.120.51:8080):
Enable Contexts Disable Contexts Stop Contexts
Balancer: brokerPREP,LBGroup: ,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 2,Ttl: 60000000,Status: OK,Elected: 0,Read: 0,Transferred: 0,Connected: 0,Load: 100
Virtual Host 1:
Contexts:
/broker, Status: ENABLED Request: 0 Disable Stop
Aliases:
prep.hg.sucive.gub.uy broker
Node ff0172b7-d027-3d85-8f60-8f3feea3707c (http://192.168.120.50:8180):
Enable Contexts Disable Contexts Stop Contexts
Balancer: brokerPREP,LBGroup: ,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 2,Ttl: 60000000,Status: OK,Elected: 0,Read: 0,Transferred: 0,Connected: 0,Load: 100
Virtual Host 1:
Contexts:
/storedproc, Status: ENABLED Request: 0 Disable Stop
Aliases:
broker prep.hg.sucive.gub.uy
-
5. Re: Can't serve multiple contexts
jplorier Aug 30, 2016 10:41 AM (in response to jfclere)I'm adding jboss virtual server configuration:
ls virtual-server=broker
configuration alias=["prep.hg.sucive.gub.uy"] enable-welcome-root=false
rewrite default-web-module=broker2013.ear name=broker
[domain@192.168.xx.xx:9999 subsystem=web] ls virtual-server=storedproc
configuration alias=["stored.prep.hg.sucive.gub.uy"] enable-welcome-root=false
rewrite default-web-module=PROJECT_NAME-ear-1.0-SNAPSHOT.ear name=storedproc
[domain@192.168.xx.xx:9999 subsystem=web] ls virtual-server=default-host
configuration alias=["prep.hg.sucive.gub.uy"] enable-welcome-root=false
rewrite default-web-module=broker2013.war name=default-host
[domain@192.168.xx.xx:9999 subsystem=web]
-
6. Re: Can't serve multiple contexts
jplorier Aug 30, 2016 10:46 AM (in response to jfclere)./subsystem=web:read-resource
{
"outcome" => "success",
"result" => {
"default-session-timeout" => 30,
"default-virtual-server" => "broker",
"instance-id" => undefined,
"native" => false,
"configuration" => {
"container" => undefined,
"static-resources" => undefined,
"jsp-configuration" => undefined
},
"connector" => {
"http" => undefined,
"ajp" => undefined
},
"valve" => undefined,
"virtual-server" => {
"default-host" => undefined,
"broker" => undefined,
"storedproc" => undefined
}
}
-
7. Re: Can't serve multiple contexts
jplorier Aug 30, 2016 1:39 PM (in response to jfclere)just in case, I've now installed mod_cluster 1.3.1 as I was running an alpha version to check if something changes.
Regards
-
8. Re: Can't serve multiple contexts
jplorier Sep 12, 2016 8:44 AM (in response to jfclere)Hi there,
Can you help me out with this? Maybe it's a simple configuration I'm missing, but I'm stuck without ideas to try any further.
Regards
-
9. Re: Can't serve multiple contexts
jfclere Sep 13, 2016 3:33 AM (in response to jplorier)It looks OK are you do the correct requests aka something like?
curl -v http://prep.hg.sucive.gub.uy:port/storedproc/
port being the port using in httpd (main server or virtualhost), basically the Host: prep.hg.sucive.gub.uy is what is routing to the right application.