Re: Back-patch use of unnamed POSIX semaphores for Linux?
Andres Freund <andres@anarazel.de>
From: Andres Freund <andres@anarazel.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-hackers@postgreSQL.org
Date: 2016-12-07T22:46:11Z
Lists: pgsql-hackers
Hi, On 2016-12-06 21:53:06 -0500, Tom Lane wrote: > Just saw another report of what's probably systemd killing off Postgres' > SysV semaphores, as we've discussed previously at, eg, > https://www.postgresql.org/message-id/flat/57828C31.5060409%40gmail.com > Since the systemd people are generally impervious to suggestions that > they might be mistaken, I do not expect this problem to go away. Would doing so actually solve the systemd issue? Doesn't systemd also remove SYSV shared memory, which we still use a tiny bit of? > I think we should give serious consideration to back-patching commit > ecb0d20a9, which changed the default semaphore type to unnamed-POSIX > on Linux. We've seen no problems in the buildfarm in the two months > that that's been in HEAD. If we don't do this, we can expect to > continue seeing complaints of this sort until pre-v10 PG releases > fall out of use ... and I don't want to wait that long. I'm a bit uncomfortable backpatching this change, before it has seen production usage. Both the posix and sysv semaphore implementation has evolved over the years, with changing performance characteristics. I don't think it's fair to users to swap a proven solution out for something that hasn't seen a lot of load. Greetings, Andres Freund
Commits
-
Make the different Unix-y semaphore implementations ABI-compatible.
- be7b2848c6d8 10.0 landed
-
Use unnamed POSIX semaphores, if available, on Linux and FreeBSD.
- ecb0d20a9d2e 10.0 cited