RedhatEL5tomcat5.5.23 with apache2.2.3

Source: Internet
Author: User
RedhatEL5tomcat5.5.23 is associated with apache2.2.3 -- Linux Enterprise Application-Linux server application information. For more information, see the following. Over the past few days, I have learned how to configure the network development environment!

After having struggled with the windows version, I want to try the linux version configuration again!

Because we can see on the Internet that the new apache does not need mod_jk to connect to tomcat anymore.

So it took more than a day to use the latest technology!

The environment is as follows:
1: redhat EL5 alas, what is the installation number, and the upgrade is not allowed! Troublesome, the store is a big bully, and it remains unchanged throughout the ages!

2: jdk-1_5_0_12-linux-i586.bin did not dare to use java6, should not have a problem! Someone seems to have used it.

3: apache2.2.3-6 this is the first time the system was built, the system was well prepared, so this time there was no trouble!

4: apache-tomcat-5.5.23.tar.gz online to download their own did not use EL5 comes with that, more package, dependency is very troublesome!

Step 1; install jdk

Unzip the jdk package and click it.

Step 2;

Install tomcat, [root @ linux ROOT] # tar-xvf apache-tomcat-5.5.23.tar.gz can be unlocked

Step 3;

In order not to affect other java environments during startup, I put JAVA_HOME and other environment variables to tomcat's own startup

In the script, for example, the tomcat directory/usr/apache-tomcat-5.5.23/bin/startup. sh and

Add the following parts to shutdown. sh, and try to add them at the front of the file content.

#----------------------------

JAVA_HOME =/usr/jdk1.5.0 _ 12 <-jdk directory extracted in step 1

JRE = $ JAVA_HOME/jre

PATH = $ JAVA_HOME/bin: $ JRE/bin: $ PATH

CLASSPATH =.: $ JAVA_HOME/bin/tools. jar: $ JAVA_HOME/lib/dt. jar

Export JAVA_HOME JRE CLASSPATH PATH

#----------------------------

Step 4: Modify apache configuration and add the following section at the end of the/etc/httpd/conf/httpd. conf file.



ServerAdmin gaohongli@cnb-net.com

DocumentRoot/usr/apache-tomcat-5.5.23/webapps/ROOT/<-this is

ServerName 127.0.0.1

ErrorLog logs/tomcat-error_log

CustomLog logs/tomcat-access_log common

ProxyPass/ajp: // localhost: 8009/

ProxyPassReverse/ajp: // localhost: 8009/

ServerName localhost

ServerAlias 127.0.0.1



Find and ensure that # is removed from the Include conf. d/*. conf line.

Step 5: Modify/etc/httpd/conf. d/proxy_ajp.conf to ensure that the following lines are removed,

LoadModule proxy_ajp_module modules/mod_proxy_ajp.so

ProxyPass/tomcat/ajp: // localhost: 8009/

ProxyPass/examples/ajp: // localhost: 8009/jsp-examples/

Step 6: Stop apache, restart tomcat, and then restart apache

Enter http: // 192.168.0.170/in the browser to view the picture of the cat.

Enter http: // 192.168.0.170/jsp-examples/and click some jsp examples to run

Note: Nowadays, these open files are changing fast, often because the file names and configuration methods are different versions.

To see the version of the left and right software I use, and if the above still does not work, remember to turn off iptables first.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.