1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00
Commit Graph

20 Commits

Author SHA1 Message Date
Volker Lendecke
45e61fcf61 s3: Add a "lock_order" argument to db_open
This will be used to enforce a lock hierarchy between the databases. We have
seen deadlocks between locking.tdb, brlock.tdb, serverid.tdb and notify*.tdb.
These should be fixed by refusing a dbwrap_fetch_locked that does not follow a
defined lock hierarchy.
2012-01-18 14:48:04 +01:00
Volker Lendecke
0f9d14820e s3: Remove a bunch of calls to procid_self()
All callers to messaging_[re]init only used procid_self()
2011-12-12 21:50:25 +01:00
Gregor Beck
c1d83b0ff2 s3:dbwrap_torture: code cleanup
Signed-off-by: Michael Adam <obnox@samba.org>
2011-11-29 18:20:06 +01:00
Michael Adam
0b7108b342 s3:dbwrap_torture: convert to using wrapper functions only 2011-10-11 14:17:56 +02:00
Michael Adam
0b5c4a601a s3:dbwrap: move all .c and .h files of dbwrap to lib/dbwrap/
Autobuild-User: Michael Adam <obnox@samba.org>
Autobuild-Date: Fri Jul 29 13:34:22 CEST 2011 on sn-devel-104
2011-07-29 13:34:22 +02:00
Michael Adam
1abdd9b2bb s3:dbwrap: move db_open() to a file dbwrap_open.c of its own.
Also start new folder lib/dbwrap/ where dbwrap_open.c is stored and
make the fallbacke implementation functoins non-static and create a
dbwrap_private.h header file that contains their prototypes.
2011-07-29 12:23:13 +02:00
Michael Adam
1679fe5ca9 s3:dbwrap_torture: use lp_load_global() 2011-07-28 11:17:35 +02:00
Günther Deschner
b2af281e50 s3-messages: only include messages.h where needed.
Guenther
2011-03-30 01:13:09 +02:00
Günther Deschner
0e771263ee s3-includes: only include system/filesys.h when needed.
Guenther
2011-03-30 01:13:07 +02:00
Andrew Bartlett
ed111d11eb s3-debug Move 'load_case_tables()' before lp_set_cmdline() and popt calls
The problem here is that we cannot run lp_set_cmdline() (directly or
indirectly via the popt helpers) until load_case_tables() has been run.

However, load_case_tables does not have auto-initialisation, so we
must init it once, and once only.

Andrew Bartlett
2010-11-02 04:36:04 +00:00
Andrew Bartlett
cf4de8ec2c s3-debug Remove 'AllowDebugChange' and use lp_set_cmdline() instead
By removing this global variable, the API between the two different
debug systems is made more similar.  Both s3 and s4 now have
lp_set_cmdline() which ensures that the smb.conf cannot overwrite
these the user-specified log level.

Andrew Bartlett
2010-11-02 04:36:04 +00:00
Andrew Bartlett
9da4ace1d9 s3-debug Impove setup_logging() to specify logging to stderr
This change improves the setup_logging() API so that callers which
wish to set up logging to stderr can simply ask for it, rather than
directly modify the dbf global variable.

Andrew Bartlett
2010-11-02 04:36:04 +00:00
Jeremy Allison
f98d217514 Change to using TDB_INCOMPATIBLE_HASH (the jenkins hash) on all
TDB_CLEAR_IF_FIRST tdb's. For tdb's like gencache where we open
without CLEAR_IF_FIRST and then with CLEAR_IF_FIRST if corrupt
this is still safe to use as if opening an existing tdb the new
hash will be ignored - it's only used on creating a new tdb not
opening an old one.

Jeremy.
2010-09-27 17:18:54 -07:00
Günther Deschner
7a05ca2c9c s3-build: use dbwrap.h only where needed.
Guenther
2010-08-26 00:25:55 +02:00
Andreas Schneider
ce2a086119 s3-popt: Only include popt-common.h when needed. 2010-08-05 12:08:31 +02:00
Volker Lendecke
752bffc53f s3: Consolidate server_id_self into the equivalent procid_self() 2010-02-23 15:30:00 +01:00
Volker Lendecke
a66c40ff38 s3:dbwrap: If "-n" is given to dbwrap_torture, open db with CLEAR_IF_FIRST 2010-02-12 23:12:10 +01:00
Günther Deschner
4f89b3993c s3-build: try to fix QNX build ("delay" is defined in lib headers).
Guenther
2009-11-25 22:07:23 +01:00
Stefan Metzmacher
14d2ca26b3 s3:dbwrap_torture: use timeval_current/timeval_elapsed instead of start_timer/end_timer
metze
2009-11-24 11:47:31 +01:00
Michael Adam
8353d47e9b s3: add dbwrap_torture - a tool to stress test tdb transactions through dbwrap
This can be used to also test tdb transactions on clustered installations
throught ctdb. The test is modeled after the ctdb_transaction.c test program
from the ctdb source code. It runs transactions in a tight loop on a test
database called "transactions.tdb" (by default), increasing a counter in each
iteration. In a clustered environment, a counter is maintained for each node.

Michael
2009-11-23 23:51:40 +01:00