[PATCH] Enable tdb mutex support in CTDB

Stefan (metze) Metzmacher metze at samba.org
Mon Jul 7 17:30:18 MDT 2014


Am 30.06.2014 07:50, schrieb Amitay Isaacs:
> Hi metze,
> 
> On Wed, Jun 25, 2014 at 5:51 PM, Stefan (metze) Metzmacher <metze at samba.org>
> wrote:
> 
>> Hi Amitay,
>>
>>> Here are the patches to enable tdb mutex support in ctdb.  It's possible
>> to
>>> enable the mutex support per node basis.
>>>
>>> Volker, I have modified your original patch to support building with
>> older
>>> version of tdb without mutex support (using configure check variable
>>> USE_TDB_MUTEX_LOCKING).  Please sign-off if you are ok with it.
>>
>> You need to use tdb_runtime_check_for_robust_mutexes() before using
>> TDB_MUTEX_LOCKING. Otherwise tdb_open_ex will fail instead of
>> ignoring TDB_MUTEX_LOCKING (as the early development version did).
>>
> 
> Done.
> 
> 
>>
>> You should use that instead of #ifdef USE_TDB_MUTEX_LOCKING
>>
> 
> Without #ifdef, you cannot build CTDB with system tdb if it is older than
> 1.3.0.  So I have kept #ifdef TDB_MUTEX_LOCKING.
> 
> 
>> Mutex support is a runtime decision not a configure time decision any
>> more.
>>
> 
>> Please test with and without '--disable-tdb-mutex-locking'.
>>
> 
> The option --disable-tdb-mutex-locking only works if you are building tdb
> library.  If you are using system tdb library to build CTDB,
> --disable-tdb-mutex-locking does not do anything.  There should be a
> warning if --disable-tdb-mutex-locking is used and building_tdb is false.
> 
> Modified patches are attached. Please review and push if ok.

Looks good, thanks!

metze

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 246 bytes
Desc: OpenPGP digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20140708/36dc4b22/attachment.pgp>


More information about the samba-technical mailing list