The specific configuration is the same as that under tomcat. Please refer to:
http://note.youdao.com/share/?id=e486a2e17eefbfab6f227dc9dddd0cef&type=note
Here are some notes:
1,
tomcat cluster Supplementary to the implementation of load balancing (session synchronization)
Because tomcat’s session synchronization function requires multicast, multicast service is enabled by default in windows, but not enabled by default in linux.
You can open route add -net 224.0.0.0 netmask 240.0.0.0 dev eth0 through the command #eth0, eth1, eth2... represents network card one, network card two, network card three
If the following conditions are met, Please use: route add -net 224.0.0.0 netmask 240.0.0.0 dev lo #This represents the local machine, eth0, eth1, eth2... represents network card one, network card two, network card three... lo represents 127.0.0.1, which is localhost
1) The address of the Receiver is auto
2) Multiple tomcats on this machine are used as a cluster
If you need to activate multicast when the server starts, you need to add eht0 net in the /etc/sysconfig/static-routes file 224.0.0.0 netmask 240.0.0.0.
For specific multicast concepts, please refer to CCNP related content.
Second,
I usually refer to project release (hot deployment), and you don’t need to add it in C/> in server.xml.
[html] view plaincopy
3. In the
server.xml element,
[html] view plaincopy