This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Tomcat and the fly likes Which Linux OS to select for Tomcat 6 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Which Linux OS to select for Tomcat 6" Watch "Which Linux OS to select for Tomcat 6" New topic
Author

Which Linux OS to select for Tomcat 6

Deeps Mistry
Ranch Hand

Joined: Jan 31, 2009
Posts: 189
Hi Everyone,

I am a newbie to Linux system.

I want to set up a Tomcat 6.x server on new Linux machine.
Can anyone give some pointers as to how should i go about with choosing the right OS , optimizing the tomcat performance by managing the memory ,different configurations to be done and so on..


Thanks
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15950
    
  19

Pretty much any Linux distro will host Tomcat6 just fine. Pick whatever one you're most comfortable with. Some distros offer Tomcat as OS-installable packages, but as a general rule, I prefer to ignore them (they're usually out-of-date) and install directly from the Tomcat downloads. I generally just unzip it into /usr/local.

How much RAM to expect depends on what your applications need. Tomcat's defaults are a reasonable start, though. Physically, I like my Tomcat servers to have at least 1MB total RAM, and ideally at least 2MB. Anything above that would be industrial-grade.


Customer surveys are for companies who didn't pay proper attention to begin with.
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19649
    
  18

I hope you mean 1GB and 2GB instead of 1MB and 2MB


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
Deeps Mistry
Ranch Hand

Joined: Jan 31, 2009
Posts: 189
Hi,

Thanks for the reply ..
I was thinking of using red hat enterprise 6

Machine 32/64 bit??

Also, 32/64 bit tomcat 6??
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15950
    
  19

I believe that RHEL 6 comes with a Tomcat RPM. Although, as I've said before, Tomcat is one of the few system components that I prefer not to install via OS application package manager. In any event, RHEL is most definitely suited for hosting Tomcat. In fact. my production systems are all based on one form of Red Hat or another.

I do recommend a 64-bit machine. Tomcat for Linux doesn't come in 32-bit/64-bit versions, although you might want to check on the JDKs available.
Deeps Mistry
Ranch Hand

Joined: Jan 31, 2009
Posts: 189
Tim Holloway wrote:I believe that RHEL 6 comes with a Tomcat RPM. Although, as I've said before, Tomcat is one of the few system components that I prefer not to install via OS application package manager. In any event, RHEL is most definitely suited for hosting Tomcat. In fact. my production systems are all based on one form of Red Hat or another.

I do recommend a 64-bit machine. Tomcat for Linux doesn't come in 32-bit/64-bit versions, although you might want to check on the JDKs available.


Ok cool..so my decision to go for RHEL 6 is good enough.

On googling, I found out various ways to tune Tomcat to have a better performance.

But is there a way to tune the Linux box in order to gain good performance?

Also, if i want to host multiple Tomcat servers on the same Linux box, how should i go about it? by using Apache?

How to improve the Linux box performance in this case?

Thanks
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15950
    
  19

There really is no way to "optimize" a system until it has an actual workload. You can optimize for what you think will need performance enhancements, but in my experience - and that of quite a few others - you'll be wrong. Appallingly wrong, in most cases.

You don't need to front Tomcat with anything unless you want a central proxy point for one or more of them or if you want to be able to avoid running Tomcat as a root-privileged user. Apache is a popular choice, but it's not the only option.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Which Linux OS to select for Tomcat 6
 
Similar Threads
integrating tomcat with apache
system.out.println in Tomcat 4.1
JDBC Driver for Sql Server 2008 on Tomcat 7 get's the connection very slow.
Hacking tomcat server
OmniGraffle Vs