JSP Tutorials - Herong's Tutorial Examples
∟Tomcat 7 Installation on Windows Systems
∟Launching Tomcat 7 Server
This section provides a tutorial example on how to launch Apache Tomcat 7 server on a Windows 7 local system by double-clicking the startup.bat file. 2 environment variables are required: CATALINA_HOME and JRE_HOME.
After installing the Tomcat package on my local Windows 7 system,
I need to learn how to properly start the Tomcat as a Web server.
1. Checking 2 required environment variables:
- CATALINA_HOME - The home directory where Tomcat is installed.
- JRE_HOME - The home directory where JRE (Java Runtime Environment) is installed.
Make sure you have Java 6 or higher installed.
2. Setting 2 required environment variables:
- Click Windows "Start" button, the right-mouse click on "Computer" to select "Properties".
- Click the "Change settings" link in the
"Computer name, domain, and workgroup settings" section.
- Click the "Advanced" tab, then the "Environment Variables" button.
- In the "User variables..." section, click the "New..." button, enter "Variable name: CATALINA_HOME" and
"Variable value: \local\apache-tomcat-7.0.32", then click "OK".
- In the "User variables..." section, click the "New..." button, enter "Variable name: JRE_HOME" and
"Variable value: \Progra~1\Java\jre7", then click "OK".
- Click "OK" buttons to close dialog boxes.
3. Launching Tomcat server:
- In Windows Explorer, go to the "\local\apache-tomcat-7.0.32\bin" folder,
and double-click on "startup.bat".
- If you see a "Windows Security Alert" dialog box showing up with
the "Windows Firewall has blocked some features of this program" message,
just click the "Cancel" button. Do not click the "Allow access" button,
so that no other computers can access your Tomcat server.
If you see a "Tomcat" window with the following message at the
end of the window, you know that the Tomcat server has been launched correctly.
... org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-apr-8080"]
... org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-apr-8009"]
... org.apache.coyote.catalina.startup.Catalina start
INFO: Server startup in 422 ms
If you want to shut down the server, you can click the "X" on the top right corner of the "Tomcat" window.
Last update: 2012.
Table of Contents
About This Book
JSP (JavaServer Pages) Overview
►Tomcat 7 Installation on Windows Systems
Downloading and Installing Tomcat 7
►Launching Tomcat 7 Server
Verifying Tomcat 7 Server
Setting Up Tomcat 7 Server Admin Access
Reviewing Tomcat 7 Server Status Page
Tomcat Web Application Manager
My First HTML Page - hello.html
My First JSP Page - hello.jsp
JSP Scripting Elements
Java Servlet Introduction
JSP Implicit Objects
Syntax of JSP Pages and JSP Documents
JSP Application Session
Managing Cookies in JSP Pages
JavaBean Objects and "useBean" Action Elements
Managing HTTP Response Header Lines
Non-ASCII Characters Support in JSP Pages
Performance of JSP Pages
EL (Expression Language)
Overview of JSTL (JSP Standard Tag Libraries)
JSTL Core Library
JSP Custom Tags
JSP Java Tag Interface
Custom Tag Attributes
Multiple Tags Working Together
File Upload Test Application
Outdated Tutorials
References
PDF Printing Version