Discussion:
Profiling
(too old to reply)
Werner vd Merwe
2004-07-23 11:23:16 UTC
Permalink
Good day all!

I posted this question in NOVICE some time ago, but have not really had any
replies.

We are running a PG7.4 database, being accessed through jsp's called through
Tomcat. The problem is, that sometimes the database comes to a complete
standstill, sometimes because of deadlocks, but I would venture to say that
most times it is because it runs out of resources.

The current hardware config is as follows:

Dual Xeon 2.4GHz CPU's
3 GB RAM
3 X WD 73 GB drives in RAID-5

My question is, are there any software or apps out there that can monitor
CPU, memory and shared buffer usage etc so I can have a pro-active way of
monitoring when we need to upgrade hardware, or just tweak the software. I
am aware that running complex queries will take a large chunk of CPU time,
but it would be good for me to have the normal running load of PG.

Hope the question makes sense.

Best regards and thank you in advance.
Werner vd Merwe
mike g
2004-07-24 03:21:02 UTC
Permalink
There are but it depends if you are running under Solaris, Linux etc.

Most of the below can be checked with applications included with your
OS.

Mike
Post by Werner vd Merwe
Good day all!
I posted this question in NOVICE some time ago, but have not really
had any replies.
We are running a PG7.4 database, being accessed through jsp’s called
through Tomcat. The problem is, that sometimes the database comes to a
complete standstill, sometimes because of deadlocks, but I would
venture to say that most times it is because it runs out of resources.
Dual Xeon 2.4GHz CPU’s
3 GB RAM
3 X WD 73 GB drives in RAID-5
My question is, are there any software or apps out there that can
monitor CPU, memory and shared buffer usage etc so I can have a
pro-active way of monitoring when we need to upgrade hardware, or just
tweak the software. I am aware that running complex queries will take
a large chunk of CPU time, but it would be good for me to have the
normal running load of PG.
Hope the question makes sense.
Best regards and thank you in advance.
Werner vd Merwe
---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster
Gaetano Mendola
2004-07-24 23:53:55 UTC
Permalink
Post by mike g
There are but it depends if you are running under Solaris, Linux etc.
Most of the below can be checked with applications included with your
OS.
Mike
and make out some graphs using cricket ( google for details ).


Regards
Gaetano Mendola
Simon Riggs
2004-07-25 22:08:35 UTC
Permalink
We are running a PG7.4 database, being accessed through jsp’s called
through Tomcat. The problem is, that sometimes the database comes to a
complete standstill, sometimes because of deadlocks, but I would
venture to say that most times it is because it runs out of resources.
It's fairly common in that kind of a set-up to issue commands that
deadlock against each other.

Worse, its possible to deadlock in your application in ways that the
database can't actually tell its a deadlock, because it can't see the
whole picture. Entity beans are just not good.

Running out of resources is a good indication of this kind of blockage,
which I hasten to add is nothing whatsoever to do with PostgreSQL - this
would occur whichever RDBMS you used.

Look at the table locking sequence in your application and try to avoid
differently ordered sequences. This may require you to redesign your
application to prevent certain page sequences that conflict badly with
the main routes.

You'll need to read up on this a lot more to understand it fully.
My question is, are there any software or apps out there that can
monitor CPU, memory and shared buffer usage etc so I can have a
pro-active way of monitoring when we need to upgrade hardware, or just
tweak the software. I am aware that running complex queries will take
a large chunk of CPU time, but it would be good for me to have the
normal running load of PG.
Check the PostgreSQL manual pages entitled "Monitoring Database
Activity". In light of the above comments, you will find this useful,
but not the answer to your problems.

Best Regards, Simon Riggs


---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to ***@postgresql.org)
Loading...