https://bugs.openldap.org/show_bug.cgi?id=9372
Issue ID: 9372 Summary: Use POSIX semaphores by default on MacOS Product: LMDB Version: unspecified Hardware: All OS: All Status: UNCONFIRMED Severity: normal Priority: --- Component: liblmdb Assignee: bugs@openldap.org Reporter: kriszyp@gmail.com Target Milestone: ---
Created attachment 775 --> https://bugs.openldap.org/attachment.cgi?id=775&action=edit Set POSIX semaphore as default for MacOS
On Apple/MacOS, System V semaphores have a limit of 10 open robust (SEM_UNDO) semaphores at once per process, which can cause problems if a process has many open database environments/transactions open at once. Using POSIX semaphores eliminates this problems and supposedly have a little bit better performance. The attached patch (also at https://github.com/kriszyp/lmdb/commit/0971512f6a4aa5b05f99e481a6687d4802f70...) sets that as the default, and reverts back to System V semaphores with MDB_USE_ROBUST, since MacOS does not support robust POSIX locking.
https://bugs.openldap.org/show_bug.cgi?id=9372
kriszyp@gmail.com kriszyp@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- OS|All |Mac OS
https://bugs.openldap.org/show_bug.cgi?id=9372
Howard Chu hyc@openldap.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution|--- |TEST
https://bugs.openldap.org/show_bug.cgi?id=9372
--- Comment #1 from Quanah Gibson-Mount quanah@openldap.org --- • d85fe32d by Kris Zyp at 2020-10-30T16:27:16+00:00 ITS#9372 Default to using POSIX semaphores on MacOS