Re: Max connections reached without max connections reached

Поиск
Список
Период
Сортировка
От Dilip Kumar
Тема Re: Max connections reached without max connections reached
Дата
Msg-id CAFiTN-v6FrBe9FTtZa-CT0r7UViWEz0_5ziU7k6cOHPhFsyMvA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Max connections reached without max connections reached  (Dilip Kumar <dilipbalaut@gmail.com>)
Список pgsql-general
On Thu, Dec 2, 2021 at 9:35 AM Dilip Kumar <dilipbalaut@gmail.com> wrote:

> I think there is no such view or anything which tells about which
> backend or transaction has more than 64 sub transaction.  But if we
> are ready to modify the code then we can LOG that information in
> GetNewTransactionId(), when first time we are marking it overflown.
> if (nxids < PGPROC_MAX_CACHED_SUBXIDS)
> {
>    MyProc->subxids.xids[nxids] = xid;
>   pg_write_barrier();
>   MyProc->subxidStatus.count = substat->count = nxids + 1;
> }
> else
> {
>   MyProc->subxidStatus.overflowed = substat->overflowed = true;
>  <-- we can log or put breakpoint here and identify which statement is
> creating oeverflow-->
> }
>
> IMHO, it is good to LOG such information if we are not already logging
> this anywhere.
>

I have prepared a small patch to log this information.

-- 
Regards,
Dilip Kumar
EnterpriseDB: http://www.enterprisedb.com

Вложения

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

Предыдущее
От: Yi Sun
Дата:
Сообщение: Re: ssl_crl_file Certificate Revocation List doesn't work for postgresql 11
Следующее
От: Daniel Frey
Дата:
Сообщение: libpq: Which functions may hang due to network issues?