Re: Connections not closing

Поиск
Список
Период
Сортировка
От Nik
Тема Re: Connections not closing
Дата
Msg-id 1137682907.555412.104810@g43g2000cwa.googlegroups.com
обсуждение исходный текст
Ответ на Connections not closing  ("Nik" <XLPizza@gmail.com>)
Ответы Re: Connections not closing
Список pgsql-general
Ok, I simplified the problem. I tried just running psql from the
command line, and I noticed that it opens two connection on two
different ports, and it closes only one.
For example I do the following in the command prompt:
---------------------------------------------------------------------------------------------
C:\> psql -h host_name -p 5432 -d db_name -U user_name
Password:
Welcome to psql 8.0.4, the PostgreSQL interactive terminal.

Type:  \copyright for distribution terms
       \h for help with SQL commands
       \? for help with psql commands
       \g or terminate with semicolon to execute query
       \q to quit

Warning: Console code page (437) differs from Windows code page (1252)
         8-bit characters may not work correctly. See psql reference
         page "Notes for Windows users" for details.

db_name=> \q

C:\>
---------------------------------------------------------------------------------------------

The corresponding entry in the log file is as follows:
---------------------------------------------------------------------------------------------
2006-01-19 09:50:29 [unknown] LOG:  connection received: host=client1
port=3775

2006-01-19 09:50:31 [unknown] LOG:  connection received: host=client1
port=3778

2006-01-19 09:50:31 test LOG:  connection authorized: user=user_name
database=db_name

2006-01-19 09:51:00 test LOG:  disconnection: session time: 0:00:29.29
user=user_name database=db_name host=client1 port=3778
---------------------------------------------------------------------------------------------

Is this normal behavior? Is the second port being closed as well just
not logged? Could this cause open connections to stick around and
eventually reach the limit and shut down the DB?

When I query pg_stat_activity it does show only one connection.


В списке pgsql-general по дате отправления:

Предыдущее
От: "Peter Zeltins"
Дата:
Сообщение: Using rowtype parameter
Следующее
От: Andreas Kretschmer
Дата:
Сообщение: Re: Replicating a remote database (backuping)