Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7fa945b

Browse files
committed
Improve warning message in pg_signal_backend()
Previously, invoking pg_terminate_backend() or pg_cancel_backend()with the postmaster PID produced a "PID XXXX is not a PostgresSQLserver process" warning, which does not make sense. Change to"backend process" to make the message more exact.Nathan Bossart, based on an idea from Bharath Rupireddy withinput from Tom Lane and Euler TaveiraDiscussion:https://www.postgresql.org/message-id/flat/CALj2ACW7Rr-R7mBcBQiXWPp=JV5chajjTdudLiF5YcpW-BmHhg@mail.gmail.com
1 parent9cb5518 commit7fa945b

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

‎src/backend/storage/ipc/signalfuncs.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,10 @@ pg_signal_backend(int pid, int sig)
5757
* arbitrary process to prevent that. But since so far all the callers of
5858
* this mechanism involve some request for ending the process anyway, that
5959
* it might end on its own first is not a problem.
60+
*
61+
* Note that proc will also be NULL if the pid refers to an auxiliary
62+
* process or the postmaster (neither of which can be signaled via
63+
* pg_signal_backend()).
6064
*/
6165
if (proc==NULL)
6266
{
@@ -65,7 +69,8 @@ pg_signal_backend(int pid, int sig)
6569
* if one backend terminated on its own during the run.
6670
*/
6771
ereport(WARNING,
68-
(errmsg("PID %d is not a PostgreSQL server process",pid)));
72+
(errmsg("PID %d is not a PostgreSQL backend process",pid)));
73+
6974
returnSIGNAL_BACKEND_ERROR;
7075
}
7176

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp