Re: [NOVICE] General Performance questions - Mailing list pgsql-general

From Tom Lane
Subject Re: [NOVICE] General Performance questions
Date
Msg-id 17571.1047311126@sss.pgh.pa.us
Whole thread Raw
In response to General Performance questions  ("Delao, Darryl W" <ddelao@ou.edu>)
List pgsql-general
"Delao, Darryl W" <ddelao@ou.edu> writes:
> I will have anywhere from 5 to 7 of these going at any given time.  However
> most say TIME_WAIT instead of established.

TIME_WAIT is a closed connection; the kernel is only remembering it for
a few seconds in case the other end requests a retransmission of the
last few outgoing bytes.  This is not blocking you from creating new
sessions.

Better ways to keep track of active database sessions are grepping the
output of "ps" for postgres processes, or watching the pg_stat_activity
system view.

> Also, is there a way to make the TIME_WAIT status shorter.

Not without violating the TCP specs.

            regards, tom lane

pgsql-general by date:

Previous
From: "Delao, Darryl W"
Date:
Subject: General Performance questions
Next
From: "Dwayne Miller"
Date:
Subject: Determining if table exists before dropping