Re: pgsql: Add kqueue(2) support to the WaitEventSet API.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pgsql: Add kqueue(2) support to the WaitEventSet API.
Дата
Msg-id 16353.1582555469@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: pgsql: Add kqueue(2) support to the WaitEventSet API.  (Thomas Munro <thomas.munro@gmail.com>)
Ответы Re: pgsql: Add kqueue(2) support to the WaitEventSet API.  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Список pgsql-hackers
Thomas Munro <thomas.munro@gmail.com> writes:
> I suppose there may be users who have set ulimit -n high enough to
> support an FDW workload that connects to very many hosts, who will now
> need to set max_files_per_process higher to avoid the new error now
> that we're doing this accounting.  That doesn't seem to be a problem
> in itself, but I wonder if the error message should make it clearer
> that it's our limit they hit here.

I struggled with the wording of that message, actually.  The patch
proposes

+            ereport(ERROR,
+                    (errcode(ERRCODE_SQLCLIENT_UNABLE_TO_ESTABLISH_SQLCONNECTION),
+                     errmsg("could not connect to server \"%s\"",
+                            server->servername),
+                     errdetail("There are too many open files.")));

I wanted to say "The server has too many open files." but in context
it would seem to be talking about the remote server, so I'm not sure
how to fix that.

We could also consider a HINT, along the lines of "Raise the server's
max_files_per_process and/or \"ulimit -n\" limits."  This again has
the ambiguity about which server, and it also seems dangerously
platform-specific.

            regards, tom lane



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

Предыдущее
От: "曾文旌(义从)"
Дата:
Сообщение: Re: [Proposal] Global temporary tables
Следующее
От: Tom Lane
Дата:
Сообщение: Re: PG v12.2 - Setting jit_above_cost is causing the server to crash