albertspick.com albertspick.com
Main >> About Us >> Add Your Link >> Privacy Policy >> Terms & Conditions >> Submit Article
Search:   
Add Url
 
 

Malls & Shopping

 

Recreation & Entertainment

 

Academics & Education

 

Fashion & Relationships

 

Law & Politics

 

Science & Research

 

Culture & Art

 

People & Society

 

Issues & News

 

Banking & Finance

 

Estate & Realty

 

Hygiene & Health

 

Jobs & Careers

 

Sports & Adventure

 

Automobile & Automotive

 

Travel & Accommodation

 

Medical Care

 

Cooking & Drinking

 

Children & Teens

 

Games & Play

 

Business & Commerce

 

Family & Home

 

Computers & Networking

 

Self Help

 

Main –› Computers & Networking –› Computer Software
 

How to Tomcat 5? Part 1

 

I had no problem with Tomcat installation and all installation packages which I tried, worked fine for me. I will not describe all installation steps, you always can find the details on it on the home site for Apache Tomcat.

It was a few years ago, when Tomcat had version 4.1.0. My first impression was that I am swimming in a swamp, so slow Tomcat was. The whole memory on my computer was consumed by Tomcat, every click on my program interface resulted in freezing the whole machine for second. The prstat (program in Solaris to supervise processes status, in Linux it is top command) indicated that CPU jumped to 100%.

After 5 years with Apache server I was completely disappointed...

I thought that those guys, that always complain about Java, are right: it is just waste of money, resources and time. This hungry (in terms of resources) monster Tomcat - will never fly!

I was not right. The problem was with settings, which were in my Tomcat installation. Having used that Apache runs perfectly right away after an installation, I was not ready for performance tuning. Honestly saying I have no clue how to do that. Especially after working with httpd.conf (Apache configuration file) it was not so easy to get into multiple xml files, where Tomcats configuration is spread around. Some strange things happened here and there

First step was to make everything working. And soon Tomcat began to work better and better.

First problem was because of additional libraries in my web applications. I could not link them from Tomcats common/lib directory. I had to have them just in one place, directly in the common/lib, no linking for another place!

Second problem was that, even if Tomcat's documentation claims that "*.war files will be discovered in webapps directory and extracted automatically", they actually sometime could be there for hours and nothing happened. Sometimes it worked, sometime did not.

So, my advice to you: if you make an installation package for distribution to many people, it will be safer to extract files from war files by your installation program and do not rely on Tomcat. And you can disable this feature at all (I do not rely on it).

How to move Tomcat from one directory to another?

My answer here is for the Solaris and Linux OSs. But it is very similar procedures for Windows.

Tomcat 5.x, comparing to earlier versions, has quite good structure and properly written configuration files. There are no files with hard coded paths or versions. Everything is read from surrounding environment and it makes Tomcat very transportable. You can easily move Tomcat from one place to another. Just update environment variable $CATALINA_HOME (this variable point to "home place" of Tomcat).

For example, on my machine default place was: /usr/local/tomcat.

Later I moved it to /home/httpd/alex.

I was running Tomcat as tomcatuser and default shell for that user was bash. To find out which shell is default in your case you need to open the file /etc/passwd and locate the line with tomcats user name. In my case this line looked like this:

tomcatuser:x:112:214:Tomcat process user/usr/local/tomcat /:/bin/bash

So, I opened the file .bashrc in home directory for tomcatuser and changed two lines:

CATALINA_HOME=/usr/local/tomcat
export CATALINA_HOME

to

CATALINA_HOME=/ home/httpd/alex
export CATALINA_HOME

Thats all. Now Tomcat 5 can run from new place.

It is just a beginning of my story about Tomcat. I continue my article about Tomcat tuning (mostly performance) in the second part.

Author: Alexandre Patchine
 
Author Bio:
Alexandre Patchine is a well-known scripter. Alexandre likes to create articles about this industry.
 
 
 

Related Articles

 
Internet Marketing Tools to Drive Targeted Visitors to Your Site
 
Top Internet Business Earns Affiliate $1.8 Million In One Year
 
Niche Market Discovery
 
The Necessity of Small Business Advertising
 
Who Really Wrote That Ebook?
 
Monitoring Software Can be Used for Spying as Well
 
The Earning Power of Good Content and Good Links
 
Only Seconds
 
How to Get Rid of Your Visitors!
 
Facing DVD Software Dilemma? It's Brainlessly Simple
 
 
 
 
 

Affiliate Marketing Tips - Honest Product Reviews

As an affiliate one of the best ways to make consistent sales is by offering your visitors honest pr ... - Mila Sidman
 

How Many Articles Can An Author Write As An Expert In A Field?

More and more smart business people are finding the value of writing articles and putting them onlin ... - Lance Winslow
 

Foreign Language Software - Learning Method Breakthrough

Learn a new language in minutes a day, with this accelerated learning method developed by a former t ... - Jeremy Brinker
 
 

Affiliate Program Sales Techniques You Can Use

The two different types of affiliate program sales need constant attention and the implementation of ... - Christopher Kyalo
 

Bar Code Scanners - Know the Features

The benefits of barcode scanners are many. It greatly helps you organize your inventory, monitor the ... - Brad J.
 
 
Main >> Privacy Policy >> Terms & Conditions
© 2008 www.albertspick.com All Rights Reserved.