Integration of Tomcat and Apache servers in Linux

Source: Internet
Author: User

Internet/Intranet Based on Web technology has been widely used in recent years. Intranet is an enterprise Intranet based on TCP/IP protocol and with Web as the core, with a low-cost, easy-to-use client browser, you can access your desired data on the enterprise's Web site anytime and anywhere.

The consistency of the browser client operation interface avoids the diversity of client programs in the C/S mode. The open and standard connection solutions on the server allow enterprises to easily contact the outside world through the Internet. At the same time, the dynamic and interactive publishing of Web Information has fundamentally changed the service quality of enterprises and increased their business opportunities.

In the opinion of many users, the success or failure of a Web site mainly lies in the content and functions it provides, and the Web server that supports these content and functions plays a very important role.

Tomcat container

Tomcat is a free and open-source Serlvet container. It is a core project of the Jakarta project of the Apache Foundation, developed by Apache, Sun, and other companies and individuals. With Sun's participation and support, the latest Servlet and Jsp specifications can always be reflected in Tomcat.

Tomcat is a solid and independent Web server and Servlet Container. However, its Web server functions are not as complete as many more sound Web servers. For example, for Apache Web servers, tomcat does not have many selective modules ). However, Tomcat is a free open-source software, and many experts are committed to its development.

Install Tomcat in Linux

Install j2sdkJava 2 Software Development Kit) before installing Tomcat. The steps for installing j2sdk are as follows:

1) to the http://www.java.sun.com to download j2sdk, such as j2sdk-1_4_2_04-linux-i586-rpm.bin.

2) Go to the directory where the j2sdk-1_4_2_04-linux-i586-rpm.bin is located in the terminal, enter the command chmod + x j2sdk-1_4_2_04-linux-i586-rpm.bin, and add the execution permission.

3) execute the command./j2sdk-1_4_2_04-linux-i586-rpm.bin to generate a j2sdk-1_4_2_04-linux-i586.rpm file.

4) execute the command chmod + x j2sdk-1_4_2_04-linux-i586.rpm to add the execution permission to the j2sdk-1_4_2_04-linux-i586.rpm.

5) execute command rpm? Ivh j2sdk-1_4_2_04-linux-i586.rpm, install j2sdk.

6) The authorization protocol will appear on the installation interface. Press Enter to accept it and install j2sd on/usr/java/j2sdk1.4.2 _ 04.

7) set the environment variable and create the file java. sh in the/etc/profile. d/directory. The file content is as follows:

# Set java environment

Export JAVA_HOME =/usr/java/j2sdk1.4.2 _ 04

Export CLASSPATH =.: $ JAVA_HOME/lib: $ JAVA_HOME/jre/lib:/usr/java/jdbc

Export PATH = $ JAVA_HOME/bin: $ JAVA_HOME/jre/bin: $ PATH

8) execute the command chmod 755/etc/profile. d/java. sh to assign permissions to java. sh.

9) execute the javac command in the terminal separately? Help and java? Version. If you see the relevant information, the j2sdk is successfully installed.

To install tomcat, follow these steps:

1) access the http://jakarta.apache.org/tomcat... ditch? Usr/local directory:

Cd/usr/local

Gzip? Zxvf jakarta-tomcat-5.5.10.tar.gz

2) modify the $ tomcat/bin/startup. sh and shutdown. sh files,

Export JAVA_HOME =/usr/java/j2sdk1.4.2 _ 04

Export CATALINA_HOME =/usr/local/tomcat-5.5.10

Export CLASSPATH =.: $ JAVA_HOME/lib: $ JAVA_HOME/jre/lib:/usr/java/jdbc

Export PATH = $ JAVA_HOME/bin: $ JAVA_HOME/jre/bin: $ PATH

3) execute startup. sh to access the default page of tomcat at http: // localhost: 8080.

  1. Use LVM to Manage Server buckets in Linux
  2. How to analyze Windows2003 server software and hardware compatibility
  3. Deploy virtual servers in a SAN Environment

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.