One day, I suddenly wanted to configure the Apache Tomcat cluster, followed by Google, opened a few online documents, and I have to write more complicated to write more but I don't know the cloud, I originally used a few words. Lecture. . . Dizzy 1. Download and install Apache, can't find the download address? Click here 2. Download the installation Tomcat, can't find the download address? Click here 3. Download the Tomcat Web Server Connectors to find a 2.0 version, why? Isn't it convenient? Can't find the download address? Click here. After decompression, copy the mod_jk2.so to the MOD_JK2.so under the modules directory. 4. Open the conf / httpd.conf file under Apac, plus one line loadModule JK2_Module Modules / MOD_JK2.SO.5. Add a workers2 in the conf directory .properties, edit the workers2.properties file, join the following
################################### = $ {serverroot} / logs / SHM .filesize = 1048576
# First Tomcat [Channel. Socket: Tomcat1] Port = 8009Host = Localhost
[AJP13: Tomcat1] channel = channel.socket: Tomcat1
# SECOND TOMCAT [CHANNEL.SOCKET: Tomcat2] port = 8009Host = 192.168.0.4 [AJP13: Tomcat2] channel: Tomcat2
# Loading balance [lb: lb1] worker = ajp13: tomcat1worker = ajp13: Tomcat2
# URI MAPPING [URI: /*]]
Group = lb: lb1 ############################################################################ Cluster, if there is only one machine, please delete the # second tomcat to the # load. 7. Start Apache8. Start Tomact9. Not successful? ? ? Email to me