PostgreSQL->JDBC->Tomcat->Apache resource uses

PostgreSQL->JDBC->Tomcat->Apache resource uses

Post by Nick Fankhause » Thu, 15 Nov 2001 05:08:51


It would be great if somebody can give me a "recipe" answer for this, but
I'm equally interested in informed conjecture and stories from similar

We're getting ready to spec our hardware for the imminent release of an
application which uses JDBC to funnel data from our database to the web via

We expect to set up a database server running PostgreSQL, an app server
running Tomcat, and a web server running Apache.

In our development environment we've observed that whenever we open a
connection to the database from the app server, a process owned by postgres
gets started on the database server. It appears that the process is the same
whether our remote client is a Tomcat servlet or psql running from the
command line.

Given this background, I have a specific question & a couple of general

How much memory should we be expecting to use for each of these processes
that get started on the server? What factors determine the load that each
one puts on system resources & what information should I gather to estimate
the impact on resources?

More generally, can someone point to an explanation of the division of tasks
between postmaster, per-client backend processes running on the database
server, and client processes running on the application side?

And finally, if anyone else is running PostgreSQL->JDBC->Tomcat->Apache, I'm
curious about your hardware configuration & experiences with it. Any
mistakes that you can help me avoid?

I've looked at Tony Grant's article on his version of this setup, & I'm
trying to digest Bruce Momjians's big "PostgreSQL Internals" article, but so
far, I haven't found these particular questions addressed.

Thanks everyone!



Ray Ontko & Co.     Software Consulting Services

---------------------------(end of broadcast)---------------------------


PostgreSQL->JDBC->Tomcat->Apache resource uses

Post by Chad R. Larso » Fri, 16 Nov 2001 05:41:06

Quote:>And finally, if anyone else is running PostgreSQL->JDBC->Tomcat->Apache,
>I'm curious about your hardware configuration & experiences with it. Any
>mistakes that you can help me avoid?

We're doing exactly the same thing, except substitute Macromedia's JRun for
Tomcat.  The Apache web server is running on its own box, for security's sake.
I believe any machine exposed to the great unwashed Internet ought to be
considered potentially compromised and hostile.  It's in it's own
firewalled DMZ.

The web server is an Intel Pentium ATX motherboard in a 1U chassis running
FreeBSD 4.3.  The Apache was built to include mod_ssl to support secure
connections.  The JRun and PostgreSQL are running on a 4 CPU Sun E3500
under Solaris 2.6.

We had issues with Tomcat when we evaluated it, hence the JRun.  Tomcat may
be fixed by now, and we may revisit that issue when the JRun license is up
for renewal.  I also see no reason other than management skittishness that
we couldn't run the backend on something like a 4 CPU 800MHz Xeon Dell
server and FreeBSD.  We've had fewer problems with the FreeBSD than with


   Eldorado Computing, Inc.   602-604-3100
      5353 North 16th Street, Suite 400
        Phoenix, Arizona   85016-3228

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?