Re: Database in use?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Database in use?
Дата
Msg-id 23817.1236025942@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Database in use?  (Carol Walter <walterc@indiana.edu>)
Ответы Re: Database in use?  (Carol Walter <walterc@indiana.edu>)
Список pgsql-admin
Carol Walter <walterc@indiana.edu> writes:
> Periodically, my databases will give me a message that says that
> someone is using the database when it appears that no one is.  What
> causes this?  What can I do about it?

What's the context exactly?

In some cases you can get this type of message because of the fact that
it takes finite time for an existing backend to exit.  For instance in

    psql -c "some command" somedb
    dropdb somedb

there's a nonzero probability that the backend launched for the psql
session will still exist when the dropdb runs.  Recent PG versions have
a hack in DROP DATABASE to wait a little bit to see if conflicting
backends will exit; but maybe you're running a version that hasn't got
that patch, or maybe you're doing something else.

            regards, tom lane

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

Предыдущее
От: Carol Walter
Дата:
Сообщение: Database in use?
Следующее
От: "Lukas"
Дата:
Сообщение: Re: Database in use?