Re: CentOS & PostgreSQL help re: TIME_WAIT

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jan 28, 2010 at 8:55 PM, Tom Lane <tgl@xxxxxxxxxxxxx> wrote:
> In general, sockets sitting a long time in TIME_WAIT would be a network
> problem.  That state means the user process already closed the socket
> and the network stack is waiting for the other end to acknowledge
> connection closure.

I think you're describing FIN_WAIT. TIME_WAIT is after the finack has
been sent and the connection is well and truly dead. The same
host/port pair can't be reused for 2*msl in case the finack needs to
be resent or a duplicate fin arrives.

Normally the server uses SO_LINGER and skips TIME_WAIT so it can
listen on the same port immediately and accept more connections.  So
only the client enters TIME_WAIT and its for some random high-numbered
port that the OS won't hand out until it expires.

If you're seeing the postgres *server* with sockets in TIME_WAIT state
for port 5432 or whatever your postgres port is then I think that's a
bug and you should report it in more detail. please send the output of
netstat -an or whatever data you have showing the problem.

If you're seeing the web server's outgoing ports in TIME_WAIT state
then I think that's normal and shouldn't be causing you problems.


-- 
greg

-- 
Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux