From: | Mikhail <mp39590(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: [PATCH] Make ENOSPC not fatal in semaphore creation |
Date: | 2021-10-23 19:02:16 |
Message-ID: | YXRcOIJm/quhGBa6@edge.lab.local |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Sun, Oct 17, 2021 at 10:52:38AM -0400, Tom Lane wrote:
> I am, however, concerned that this'll just trade off one hazard for
> another. Instead of a risk of failing with ENOSPC (which the DBA
> can fix), we'll have a risk of kneecapping some other process at
> random (which the DBA can do nothing to prevent).
I tend to agree, and along with semas patch would like to suggest error
message improvement, it would have saved me about half a day of digging.
Tested on OpenBSD 7.0.
I'm not a native speaker though, so grammar need to be checked.
diff --git a/src/backend/port/sysv_sema.c b/src/backend/port/sysv_sema.c
index 21c883ba9a..b84f70b5e2 100644
--- a/src/backend/port/sysv_sema.c
+++ b/src/backend/port/sysv_sema.c
@@ -133,7 +133,10 @@ InternalIpcSemaphoreCreate(IpcSemaphoreKey semKey, int numSems)
"respective kernel parameter. Alternatively, reduce PostgreSQL's "
"consumption of semaphores by reducing its max_connections parameter.\n"
"The PostgreSQL documentation contains more information about "
- "configuring your system for PostgreSQL.") : 0));
+ "configuring your system for PostgreSQL.\n"
+ "If server has crashed previously there may be resources left "
+ "after it - take a look at ipcs(1) and ipcrm(1) man pages to see "
+ "how to remove them.") : 0));
}
return semId;
From | Date | Subject | |
---|---|---|---|
Next Message | Floris Van Nee | 2021-10-23 19:30:47 | RE: MDAM techniques and Index Skip Scan patch |
Previous Message | Jeff Davis | 2021-10-23 18:54:53 | Re: add retry mechanism for achieving recovery target before emitting FATA error "recovery ended before configured recovery target was reached" |