The branch, 1.0.114 has been updated
       via  10dce70bf8a238702a5b81ffa8ea89edea9fc61f (commit)
       via  09c76d906a8e79ff74578d617432dd76c504f700 (commit)
       via  ef41e0d2173a208a6536238f9829fb99b1394a44 (commit)
       via  2e324e2a5000b4eb6676bee35ff2a885f992a159 (commit)
       via  7f8bf1e36410b6513078c1004ced55d5e8950a52 (commit)
       via  bc22f94f68a346e8e867a91aa05e0be27accb2ba (commit)
       via  7f73968b20be32754b71f88840443797730f24a8 (commit)
       via  1f81243770c16daf2755205598c3ed5677bdaa25 (commit)
       via  52d5095790e8be9f46e9dcb3eb3f4763a0442eda (commit)
       via  b442fe628a0c7a967432f5900c850d7b27a2958f (commit)
       via  9339dcbd00deabd3ecdcef552ef62777b0b74cfe (commit)
       via  4c17aa592039b4e6c4db21aae8f463a931ad4185 (commit)
       via  a7d1706c8ebfaa701a7de26f5bceb380cf7f5eb5 (commit)
       via  2c2eacd2582013e7d7066fa20b7deefcb3086951 (commit)
       via  2b1b769953f4b0eb922febff625470d0ac12bf3c (commit)
       via  25ec7c15aa73f238262ebd629b87a00f17ca3291 (commit)
       via  817f792859e1d27538240e81f24f6220881c1847 (commit)
       via  6df39465cade56768d8f039ba9ddd4da4894fbbc (commit)
       via  a43455c4529602d58115baa7619021bcc0ed63bf (commit)
       via  de96bae3f567bd1f4de66118792638daa259a635 (commit)
       via  cd81d32b5646906663c713af6615ba90f4de3445 (commit)
       via  76521192d6dc8759caeb88a0868eb96b8c44c80a (commit)
       via  b41b8388055c3e390851306b4efb10950985668c (commit)
       via  a0d4d199362497b0e5f6eec2c2619ffa6d20bfb6 (commit)
       via  cadad9bf4ca2f636cc97062f7b02b05127d3aac7 (commit)
       via  c616a26447f470208577bbc7df50eae881da3f55 (commit)
       via  e83baa1242b9f120fea4ba778168e5d0a3822f96 (commit)
       via  b05b413bc49fdab4723dd47e71bb10f454a7756e (commit)
       via  f0925fc2802dad4f73f2e1dfd980273e18d3d6a2 (commit)
       via  9eaf33552513a082940731639f30e0b42bf3865d (commit)
       via  3c14c72ea749230264165a7f6dea0b7779ae9f75 (commit)
       via  e978f49e507cbbe0211453b5658e69a243d61f5f (commit)
       via  ce32c2f05cd998c1f8b76108bd51ff10e42fcb01 (commit)
       via  9351e4d8081f9197c7fa8b407c747731326697fa (commit)
       via  a1c3aca9a7c6be049bd1e1ce73837eafde4ec847 (commit)
       via  c4bf65859a6d61c01d94ade7bbbf4eee28d3682d (commit)
       via  f8136e7362a8784b80a8aa6a3b4a193964856002 (commit)
       via  fd92aab082cd80bf7e495b4ffcd14777843b3664 (commit)
       via  988e2eeb8a19d0b5b4f90fb8f1a6e20fabc4f34b (commit)
       via  793a9469a7c7fcf48e6210dc2a3ec240d6fd7ec2 (commit)
       via  a2297986cb34972d719e286f683a5a4be802b1b0 (commit)
       via  df8848de3f6d7cee8c3d31bc412ea1f7edca33c0 (commit)
       via  99185969ea0bd298e11408f526b07ff1435caa9c (commit)
       via  85c90854c70023e966aba7ef63de83153d29005c (commit)
       via  d89e9686fcfb147515155a082e08f16645efade8 (commit)
       via  451843e4251c2c8a4393fd2b3dbd83a5b8036f5b (commit)
       via  c9231900a7a356b77741fbc45af39702e524ecd6 (commit)
       via  9f123c01ea118623d02d95cd4e39d92717acd600 (commit)
       via  470f9ecddd7288199c8a5224eca46fcb966688ff (commit)
       via  686bf255af9f4ff965f4987677074ea6edacdb31 (commit)
       via  c3d1b5f405e7474759b38292ffd5e1b91a726f3b (commit)
       via  44668022af30d1386924e6ec620adab8b7c4465c (commit)
       via  aa4b194516bca264450b38ab174b8520c22fe4c0 (commit)
       via  00719defe07966d473a92a12d52787c80f9d6a93 (commit)
       via  cab84f289f774397574351fd081da0cb177fe2ed (commit)
       via  9445f108d705dfe500431fc12a58134078f427db (commit)
       via  1a8813f1eb734d86c39cba76c5dc1b8814df47ad (commit)
       via  91dcc9e08dfa6e3609f6e625b22dd913d9d53229 (commit)
       via  37f82d3d531f5a5db59745586f48af820e9f47c8 (commit)
       via  b0a6758e7e31aee5179f251e3b0c61b286eba489 (commit)
       via  0eefb7dce5f0a4fb72bbcaa1062bf7e0e4ff0fbf (commit)
       via  4b15ff406f87a0e25dd23ab5f327bb8cc780a6e9 (commit)
       via  a39b06f6c74a55b6fb910a7f73872a67d290df52 (commit)
       via  97dcd371a733cf98f8c646acd9d571ddbaf025c1 (commit)
       via  b48a5f21b3a87550fc5ecc7016f5d02ea4956ddf (commit)
       via  0c966a5be2398f3f676c0ceadfa2d143f7646bc5 (commit)
       via  2c00993aff00d9db57539baeb0fa6e5f2fa4cec0 (commit)
       via  b2b0ac626dd8c4206f3cb1059527bd5cb56a012e (commit)
       via  6bc88b966f3f1da4fb27911fc9023f4f609ef46c (commit)
       via  db02dc3d80d311ed932975765c004f2d0c9f51ff (commit)
       via  3aabb0ea3b512d7474564bc7bae9ec6925fa25ef (commit)
       via  4c5589f6c7334445eb215025d98e12d48fde9cd3 (commit)
       via  7b45aa95c8c98991897905109090449318eaaea6 (commit)
       via  cbcf3b4983a63d52110e23cd97ffc8b612dc477c (commit)
       via  1a9e95992e6962b06ae9502391d10dd966dbd7ef (commit)
       via  cc179bf2e72b6922a032a691fdb3e4e43ecb4386 (commit)
       via  500405bb626bef80e41662753853b940c0095da2 (commit)
       via  000c4f89de401435be93d33abf109f0efc6c71f2 (commit)
       via  2b0cf32fe1494ca3aeb08a98c03b20a04c9be7ca (commit)
      from  0dfc98ebacfd72a7fb9bf340260f00f5eed7355e (commit)

http://gitweb.samba.org/?p=ctdb.git;a=shortlog;h=1.0.114


- Log -----------------------------------------------------------------
commit 10dce70bf8a238702a5b81ffa8ea89edea9fc61f
Author: Michael Adam <ob...@samba.org>
Date:   Thu Jan 12 14:47:50 2012 +0100

    New version 1.0.114.4
    
    Includes vacuuming fixes and cleanup.

commit 09c76d906a8e79ff74578d617432dd76c504f700
Author: Michael Adam <ob...@samba.org>
Date:   Thu Jan 12 12:46:06 2012 +0100

    ltdb_server: improve logging in ctdb_ltdb_store_server
    
    When logging which key to store/delete, list the ctdb_hash
    and the jenkins_hash. In this version, the databases still
    use the the old hash (with lots of hash collisions) while
    the internal lists (vacuuming, schedule_for_deletion, ...)
    already use the jenkins hash.

commit ef41e0d2173a208a6536238f9829fb99b1394a44
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:48:38 2011 +0100

    doc:ctdb.1: add generated files after update

commit 2e324e2a5000b4eb6676bee35ff2a885f992a159
Author: Michael Adam <ob...@samba.org>
Date:   Thu Dec 22 13:05:26 2011 +0100

    doc:ctdb.1: explain that "ctdb listvars" does not list obsolete tunables 
any more
    (cherry picked from commit 4ed94279f243729d521d365a44607fd086ae7c41)

commit 7f8bf1e36410b6513078c1004ced55d5e8950a52
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:47:42 2011 +0100

    doc:ctdb.1: adapt example output of "ctdb listvars" to current state

commit bc22f94f68a346e8e867a91aa05e0be27accb2ba
Author: Michael Adam <ob...@samba.org>
Date:   Thu Dec 22 12:13:10 2011 +0100

    ctdb-tool: adapt formatting of "listvars" output to lenght of longest name
    (cherry picked from commit 295168d99183d2d21f27a8ac6825d421fa866b28)

commit 7f73968b20be32754b71f88840443797730f24a8
Author: Michael Adam <ob...@samba.org>
Date:   Thu Dec 22 12:52:55 2011 +0100

    tunables: don't list obsolete tunables in the list_tunables control
    (cherry picked from commit d8ab86f0eb11437e50d18183858dd3177a8f61e6)

commit 1f81243770c16daf2755205598c3ed5677bdaa25
Author: Michael Adam <ob...@samba.org>
Date:   Thu Jan 12 00:08:03 2012 +0100

    tunables: add a bool obsolete flag to the tunable_map list
    
    (cherry picked from commit 1a7d9b25fdcf7b59598618d406c2a681c90d9163)

commit 52d5095790e8be9f46e9dcb3eb3f4763a0442eda
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 23 17:23:07 2011 +0100

    vacuum: improve logging in remove_record_from_delete_queue()
    (cherry picked from commit 809d1f3b8a9232fce0376cb47e4f633b49237529)

commit b442fe628a0c7a967432f5900c850d7b27a2958f
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 23 17:22:46 2011 +0100

    vacuum: improve logging in delete_record_traverse()
    (cherry picked from commit 40ca781b3305d9f0bfee5b109d4eefde461a3f13)

commit 9339dcbd00deabd3ecdcef552ef62777b0b74cfe
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 23 17:10:20 2011 +0100

    vacuum: improve logging in insert_record_into_delete_queue()
    (cherry picked from commit db59ac2ee6a9f5f7f088ebbc5e2800d9e57aae17)

commit 4c17aa592039b4e6c4db21aae8f463a931ad4185
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 23 17:08:28 2011 +0100

    vacuum: improve debugging in delete_queue_traverse()
    (cherry picked from commit 2c44c6dc583872c603a399afb01936abcbb05158)

commit a7d1706c8ebfaa701a7de26f5bceb380cf7f5eb5
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 23 15:14:06 2011 +0100

    vacuum: add debug message to insert_record_into_delete_queue() for failed 
insert
    (cherry picked from commit ae78e8d991636a3a79dd9fbcefc15032afb08f55)

commit 2c2eacd2582013e7d7066fa20b7deefcb3086951
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 23 10:37:25 2011 +0100

    vacuum: improve debugging in insert_record_into_delete_queue()
    (cherry picked from commit 6e6aaba28ac560d51d7450ebcf99babf868d0aea)

commit 2b1b769953f4b0eb922febff625470d0ac12bf3c
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 23 00:14:18 2011 +0100

    vacuum: initialize (to zero) the vacuum fetch list in 
ctdb_vacuum_init_vacuum_data()
    (cherry picked from commit 772e08c29ef70a4cc73f7887939e5071a90a98cb)

commit 25ec7c15aa73f238262ebd629b87a00f17ca3291
Author: Michael Adam <ob...@samba.org>
Date:   Thu Dec 22 15:46:49 2011 +0100

    vacuum: add statistics output for processing of the delete list
    (cherry picked from commit bec2ff46402b6d90521c75e8d46b9f6f2f47239a)

commit 817f792859e1d27538240e81f24f6220881c1847
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 20 15:58:34 2011 +0100

    vacuum: add a comment explaining a race in the vacuum code.
    (cherry picked from commit 07f1ba54b1617fadd6fe83826dd8e76f37cea071)

commit 6df39465cade56768d8f039ba9ddd4da4894fbbc
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 20 15:50:51 2011 +0100

    vacuum: factor out initialization of the vacuum data from ctdb_vacuum_db()
    
    for readability
    (cherry picked from commit 1963e33859e9dc51e9e88664c6d95e62c7c8b8be)

commit a43455c4529602d58115baa7619021bcc0ed63bf
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 23:16:27 2011 +0100

    vacuum: streamline ctdb_process_delete_list()
    
    Reducing indentiation and improving use of talloc.
    (cherry picked from commit 11f52ba18370f1dda983f2263f9af82045b4fdea)

commit de96bae3f567bd1f4de66118792638daa259a635
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 23:15:51 2011 +0100

    vacuum: factor processing of the delete list out of ctdb_vacuum_db()
    (cherry picked from commit cf68b762432a18e4a3cda137591b3f005c196906)

commit cd81d32b5646906663c713af6615ba90f4de3445
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 17:00:07 2011 +0100

    vacuum: factor processing of vacuum fetch lists out of ctdb_vacuum_db()
    
    (cherry picked from commit 905fc9cd7126ab84c23d4a803c59e32b9c54e6f0)

commit 76521192d6dc8759caeb88a0868eb96b8c44c80a
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 11:04:13 2011 +0100

    vacuum: factor out full vacuum run out of ctdb_vacuum_db() as 
ctdb_vacuum_db_full()
    (cherry picked from commit e31594e0c13899e88013ce7eb7e3dc434c2f0723)

commit b41b8388055c3e390851306b4efb10950985668c
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 10:59:26 2011 +0100

    vacuum: factor out the fast vacuuming run into ctdb_vacuum_db_fast()
    
    for readability
    (cherry picked from commit 6596f2c4a6b4783b6498502fbbf50f87d4f59085)

commit a0d4d199362497b0e5f6eec2c2619ffa6d20bfb6
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 10:53:26 2011 +0100

    vacuum: rename delete_tree to delete_list
    
    It is not important for the user that this is implemented as a tree.
    (cherry picked from commit f686bc440560074c1ce866f2037ae3671f182185)

commit cadad9bf4ca2f636cc97062f7b02b05127d3aac7
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 10:49:41 2011 +0100

    vacuum: appropriately rename vdata.list to vdata.vacuum_fetch_list
    (cherry picked from commit 09c55b76c96c4ab3fe812763007b81cf0a2ac86c)

commit c616a26447f470208577bbc7df50eae881da3f55
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 10:46:54 2011 +0100

    vacuum: introduce a helper variable for the vacuum fetch list in 
ctdb_vacuum_db()

commit e83baa1242b9f120fea4ba778168e5d0a3822f96
Author: Michael Adam <ob...@samba.org>
Date:   Fri Dec 16 10:43:06 2011 +0100

    vacuum: introduce a helper variable in add_record_to_vacuum_fetch_list() to 
reduce verbosity
    (cherry picked from commit 48fe56ea27e3649ae7a67257fdce54f973e7c3c5)

commit b05b413bc49fdab4723dd47e71bb10f454a7756e
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 17:43:58 2011 +0100

    tools/ctdb: allow the "ctdb vacuum" stub to be run without the daemon 
running.
    
    (cherry picked from commit e71afbf731f06a3b89b64220c7fd1b1ea5492d4a)

commit f0925fc2802dad4f73f2e1dfd980273e18d3d6a2
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 17:43:10 2011 +0100

    tools/ctdb: remove functionality of "ctdb vacuum", just keeping a stub.
    
    (cherry picked from commit 8fc4d5018ee6eee8856634095694d3ad0de5b4ae)

commit 9eaf33552513a082940731639f30e0b42bf3865d
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 17:32:45 2011 +0100

    vacuum: locally delete the records in the delete_tree that have be deleted 
remotely
    
    This way, especially records added in the fast vacuuming runs
    are deleted direclty instead of being handed back to the
    repack run which will probably not hit because of the vacuum limit.
    (cherry picked from commit ea3e640a28178ddcb85285f4efec62ccba2483d9)

commit 3c14c72ea749230264165a7f6dea0b7779ae9f75
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 17:30:39 2011 +0100

    vacuum: improve vacuuming statistics for handling the delete_tree.
    
    Track the number of records failed to delete remotely with the
    TRY_DELETE_RECORDS control.
    And add a number of records left to delete locally.
    (cherry picked from 536aad024d52f2c32dd397fc86294c963b91341b)

commit e978f49e507cbbe0211453b5658e69a243d61f5f
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 16:05:05 2011 +0100

    vacuum: fix and improve a comment
    (cherry picked from commit 0ed349c24c7399b3b440c1f5d573db77ddb988b3)

commit ce32c2f05cd998c1f8b76108bd51ff10e42fcb01
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 15:59:38 2011 +0100

    vacuum: appropriately rename delete_traverse()  to 
delete_marshall_traverse()
    (cherry picked from commit 7c5b27bc8dce9e30f2aff05297113da981f7b9a3)

commit 9351e4d8081f9197c7fa8b407c747731326697fa
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 15:58:52 2011 +0100

    vacuum: initialize the delete_count in the vacuum data
    (cherry picked from commit 970b8fc60857ad2f18f45312d355c571fb2f0246)

commit a1c3aca9a7c6be049bd1e1ce73837eafde4ec847
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:21:04 2011 +0100

    vacuum: fix the VacuumInterval tunable's type to uint32_t in 
get_vacuum_interval()
    (cherry picked from commit a5a29bf92b23e9b5a1523b06461eced422b22ffe)

commit c4bf65859a6d61c01d94ade7bbbf4eee28d3682d
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:33:08 2011 +0100

    vacuum: add new tunable VacuumInterval and mark 
Vacuum{Default,Min,Max}Interval obsolete
    
    And use VacuumInterval instead of VacuumDefaultInterval in the code.
    (cherry picked from commit 78530f40338f511a7cd1d33ada450905742bfa8f)

commit f8136e7362a8784b80a8aa6a3b4a193964856002
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:36:35 2011 +0100

    vacuum: remove struct vacuum_tuning_data (unused)
    (cherry picked from commit 1f62afbe1ae0b3e7dbad4081d1b51e3ab6ee5c39)

commit fd92aab082cd80bf7e495b4ffcd14777843b3664
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:32:12 2011 +0100

    vacuum: use get_vacuum_interval() in ctdb_vacuum_event()
    
    (instead of using the tunable directly)
    (cherry picked from commit e40fa9efd1c77aa35c917aba6e6e4d21d9c5cdea)

commit 988e2eeb8a19d0b5b4f90fb8f1a6e20fabc4f34b
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:16:23 2011 +0100

    vacuum: change get_vacuum_interval() to simply return the 
VacuumDefaultInterval tunable
    
    (cherry picked from commit 621c3ce957cb946ca05a2d527c037746ae2f01d3)

commit 793a9469a7c7fcf48e6210dc2a3ec240d6fd7ec2
Author: Michael Adam <ob...@samba.org>
Date:   Tue Dec 13 14:06:09 2011 +0100

    vacuum: remove update_tuning_db()
    
    (cherry picked from commit d93750ea3f5cb854e5893e53795fd08656e7c12c)

commit a2297986cb34972d719e286f683a5a4be802b1b0
Author: Michael Adam <ob...@samba.org>
Date:   Thu Apr 7 12:17:42 2011 +0200

    ctdb_ltdb_store_server: when storing a record that is not to be scheduled 
for deletion, remove it from the delete queue
    
    Pair-Programmed-With: Stefan Metzmacher <me...@samba.org>
    (cherry picked from commit 489148e465e2b8aed87ea836e3518f43490671ca)

commit df8848de3f6d7cee8c3d31bc412ea1f7edca33c0
Author: Michael Adam <ob...@samba.org>
Date:   Thu Apr 7 12:17:16 2011 +0200

    vacuum: add ctdb_local_remove_from_delete_queue()
    
    Pair-Programmed-With: Stefan Metzmacher <me...@samba.org>
    (cherry picked from commit a5065b42a98c709173503e02d217f97792878625)

commit 99185969ea0bd298e11408f526b07ff1435caa9c
Author: Michael Adam <ob...@samba.org>
Date:   Thu Dec 22 18:09:36 2011 +0100

    rb_tree: fix possible access-after-free-error in trbt_traversearray32_node
    
    When the traverse callback frees the current node, the traverse of the
    rbtree can fail (the next node->right fails since node is not there any 
more...).
    This is fixed by introducing variables to store the right (and left)
    pointers before the callback is called.
    (cherry picked from commit 8b0caaeed154d26c67a73659d3bbbdd63b21be11)

commit 85c90854c70023e966aba7ef63de83153d29005c
Author: Michael Adam <ob...@samba.org>
Date:   Thu Dec 22 17:18:38 2011 +0100

    fix zero-initialization of header in _ctdbd_allocate_pkt to the correct size
    (cherry picked from commit 6c4d1b768ccade344a7462ecad7cf5cbbf3873d4)

commit d89e9686fcfb147515155a082e08f16645efade8
Author: Ronnie Sahlberg <ronniesahlb...@gmail.com>
Date:   Wed Dec 14 12:52:35 2011 +1100

    typo
    (cherry picked from commit 8fc71ad4da746e28406c06a95928052b29803062)

commit 451843e4251c2c8a4393fd2b3dbd83a5b8036f5b
Author: Michael Adam <ob...@samba.org>
Date:   Sat Dec 3 02:15:30 2011 +0100

    traverse: fix traversing with empty records by adding a new (internal) 
control CTDB_CONTROL_TRAVERSE_START_EXT
    
    By this, the original CTDB_CONTROL_TRAVERSE_START control that is
    used by e.g. samba's smbstatus, is not changed, so that samba
    continues working without code change.
    
    The  CTDB_CONTROL_TRAVERSE_START currently just adds the "withemptyrecords"
    flag to the state and processon on as CTDB_CONTROL_TRAVERSE_START_EXT.
    (cherry picked from 8281bb210858ed04992eacea7f6d02261e0fc1b1)

commit c9231900a7a356b77741fbc45af39702e524ecd6
Author: Michael Adam <ob...@samba.org>
Date:   Tue Jan 10 14:15:26 2012 +0100

    doc: commit generated ctdb.1 manpages after xml change

commit 9f123c01ea118623d02d95cd4e39d92717acd600
Author: Michael Adam <ob...@samba.org>
Date:   Tue Nov 29 13:41:16 2011 +0100

    doc: document the "--print-recordflags" parameter to "ctdb"
    (cherry picked from commit 5b527e6127a649fa80dcf9a7599b22bcb7cd3640)

commit 470f9ecddd7288199c8a5224eca46fcb966688ff
Author: Michael Adam <ob...@samba.org>
Date:   Tue Nov 29 10:24:52 2011 +0100

    ctdb: add an option --print-recordflags to trigger printing record flags in 
catdb and dumpdbbackup
    
    This changes the default behaviour to not print record flags.
    (cherry picked from commit 2d2ce07c51055d9400b22cd3c1fd682597cb921c)

commit 686bf255af9f4ff965f4987677074ea6edacdb31
Author: Michael Adam <ob...@samba.org>
Date:   Tue Nov 29 13:39:08 2011 +0100

    doc: document the "--print-hash" parameter to "ctdb".
    (cherry picked from commit 998b7f4450026051867525d91c6d8dcbd2326ab5)

commit c3d1b5f405e7474759b38292ffd5e1b91a726f3b
Author: Michael Adam <ob...@samba.org>
Date:   Mon Jan 3 13:15:34 2011 +0100

    ctdb: add output of jenkins hash to ctdb catdb (with --print-hash)

commit 44668022af30d1386924e6ec620adab8b7c4465c
Author: Michael Adam <ob...@samba.org>
Date:   Tue Nov 29 00:56:23 2011 +0100

    ctdb: add an option --print-hash to enable printing of record hashes when 
dumping dbs
    
    (cherry picked from commit efc033c28ade97f9884794256d59a4553e052d5f)

commit aa4b194516bca264450b38ab174b8520c22fe4c0
Author: Michael Adam <ob...@samba.org>
Date:   Tue Nov 29 13:36:38 2011 +0100

    doc: document the "--print-lmaster" parameter to "ctdb"
    (cherry picked from commit 7e7d86ac9b05f8b67414200adc8ac87cfccf26cf)

commit 00719defe07966d473a92a12d52787c80f9d6a93
Author: Michael Adam <ob...@samba.org>
Date:   Mon Nov 28 17:36:03 2011 +0100

    ctdb: add an option --print-lmaster to enable printing of lmaster in "ctdb 
catdb"
    
    (cherry picked from commit 326f88ef622620cb9e0569c4497bc0e86124beaa)

commit cab84f289f774397574351fd081da0cb177fe2ed
Author: Michael Adam <ob...@samba.org>
Date:   Tue Nov 29 13:31:11 2011 +0100

    doc: document the "--print-datasize" parameter to "ctdb"
    (cherry picked from commit 9e8045a5b0d8bd9ab2e0343b329de9f45b883531)

commit 9445f108d705dfe500431fc12a58134078f427db
Author: Michael Adam <ob...@samba.org>
Date:   Mon Nov 28 17:19:03 2011 +0100

    ctdb: add an option --print-datasize to only print datasize instead of 
dumping data in db dumps
    
    Used in catdb and dumpdbbackup.
    (cherry picked from commit dd866116041e71cbf91e7fd91edcc9501634051d)

commit 1a8813f1eb734d86c39cba76c5dc1b8814df47ad
Author: Michael Adam <ob...@samba.org>
Date:   Tue Nov 29 13:28:35 2011 +0100

    doc: document the --print-emptyrecords switch in the "ctdb" manpage.
    (cherry picked from commit 7b4663dd2454b798841815044f898dead9b734e2)

commit 91dcc9e08dfa6e3609f6e625b22dd913d9d53229
Author: Michael Adam <ob...@samba.org>
Date:   Mon Nov 28 17:11:16 2011 +0100

    ctdb: add an option --print-emptyrecords to enable printing of empty 
records in dumping databases
    
    this option is used with the commands catdb and dumpdbbackup.
    (cherry picked from commit 6ec68a2e667f66d2b194fe48cb75229a2777842e)

commit 37f82d3d531f5a5db59745586f48af820e9f47c8
Author: Michael Adam <ob...@samba.org>
Date:   Wed Dec 22 12:45:06 2010 +0100

    client: add version ctdb_traverse_ext() of ctdb_traverse() that can list 
empty records.
    (cherry picked from commit 4ada4bfc4510886c5c7fcf49e09711b9d2dcb75d)

commit b0a6758e7e31aee5179f251e3b0c61b286eba489
Author: Michael Adam <ob...@samba.org>
Date:   Sun Nov 27 23:16:33 2011 +0100

    traverse: add a flag to enable transferring empty records in cluster wide 
traverse
    
    This will be useful for also printing information about empty/deleted
    records in "ctdb catdb", e.g. for debugging vacuuming issues.
    (cherry-picked from commit ddc5da3a0df7701934404192a0a0aa659a806acb)

commit 0eefb7dce5f0a4fb72bbcaa1062bf7e0e4ff0fbf
Author: Michael Adam <ob...@samba.org>
Date:   Sat Nov 26 01:06:13 2011 +0100

    vacuum: update (C) from vacuum rewrite
    (cherry picked from commit a95b524e57b861416f65baef7a0235bf7e394cef)

commit 4b15ff406f87a0e25dd23ab5f327bb8cc780a6e9
Author: Michael Adam <ob...@samba.org>
Date:   Fri Nov 25 13:55:20 2011 +0100

    vacuum: write a big and up-to-date explaining comment for ctdb_vacuum_db()
    (cherry picked from commit 6b9d308985ef2363c62fde6340ad37d56f6d7702)

commit a39b06f6c74a55b6fb910a7f73872a67d290df52
Author: Michael Adam <ob...@samba.org>
Date:   Fri Nov 25 13:54:48 2011 +0100

    vacuum: fix a comment typo in vacuum_traverse()
    (cherry picked from commit 88ad1e75c686cd47aec18b0a8eb93c3b125f0e97)

commit 97dcd371a733cf98f8c646acd9d571ddbaf025c1
Author: Michael Adam <ob...@samba.org>
Date:   Fri Nov 25 13:35:05 2011 +0100

    vacuum: fix horrible indentation/whitespacing for ctdb_vacuum_event()
    (cherry picked from commit 0f070a65a322bd6d3240ca96a9e5c3633ef647bf)

commit b48a5f21b3a87550fc5ecc7016f5d02ea4956ddf
Author: Michael Adam <ob...@samba.org>
Date:   Fri Nov 25 13:34:15 2011 +0100

    vacuum: fix a comment typo in vacuum_traverse()
    (cherry picked from commit 39a5c0d8cca4ce5e8bc7055739a6377fb2dc36e0)

commit 0c966a5be2398f3f676c0ceadfa2d143f7646bc5
Author: Michael Adam <ob...@samba.org>
Date:   Fri Nov 25 13:25:27 2011 +0100

    vacuum: fix an abundance of indentation white spaces in ctdb_vacuum_db()
    (cherry picked from commit 4ae564e415560cde7e4cd4c5a1d7699f3d49621b)

commit 2c00993aff00d9db57539baeb0fa6e5f2fa4cec0
Author: Michael Adam <ob...@samba.org>
Date:   Fri Nov 25 13:23:23 2011 +0100

    vacuum: rename "size" to "freelist_size" for clarity
    (cherry picked from commit 057023f5843c91d1cf8512f3675a01a119ea6157)

commit b2b0ac626dd8c4206f3cb1059527bd5cb56a012e
Author: Ronnie Sahlberg <ronniesahlb...@gmail.com>
Date:   Wed Nov 2 13:33:28 2011 +1100

    RB_TREE: Add mechanism to abort a traverse
    
    This patch changes the callback signature for traversal
    functions to allow a client to abort a traverse before it finishes.
    Updates to all callers and examples as well as rb-test tool.
    (cherry picked from commit 8ab0c63ad36cfbbb1e5fed46a1f4c47b1fdb581f)

commit 6bc88b966f3f1da4fb27911fc9023f4f609ef46c
Author: Mathieu Parent <math.par...@gmail.com>
Date:   Wed Mar 23 00:16:27 2011 +0100

    Correction of spelling errors
    
    * continous -> continuous
    * activete  -> activate
    
    (thanks to lintian)
    
    See https://bugzilla.samba.org/show_bug.cgi?id=6935
    
    Signed-off-by: Michael Adam <ob...@samba.org>
    (cherry picked from commit fb6987c2f747d6dbf9bb3899a480124d1c242a90)

commit db02dc3d80d311ed932975765c004f2d0c9f51ff
Author: Rusty Russell <ru...@rustcorp.com.au>
Date:   Wed Jul 21 12:28:04 2010 +0930

    vacuum: disabling vacuuming during a freeze
    
    We shouldn't even think about vacuuming when we've frozen the database
    (which is earlier than when we set CTDB_RECOVERY_ACTIVE)
    
    CQ:S1018154 & S1018349
    Signed-off-by: Rusty Russell <ru...@rustcorp.com.au>
    (cherry picked from commit d8df6835a931082af232c4b94f1dede6f16169f9)
    
    Signed-off-by: Michael Adam <ob...@samba.org>

commit 3aabb0ea3b512d7474564bc7bae9ec6925fa25ef
Author: Rusty Russell <ru...@rustcorp.com.au>
Date:   Mon Jul 26 16:08:07 2010 +0930

    vacuum: fix crash on vacuum abort
    
    Martin Schwenke discovered that 517f05e42f17766b1e8db8f1f4789cbad968e304
    ("freeze: abort vacuuming when we're going to freeze.") used ctdb_db for
    a logging message which is in fact uninitialized, causing a crash (even
    if it wasn't actually logged).
    
    Initialize it properly.  Also fix incorrect format in another logging
    message introduced in that same change.
    
    CQ:S1019093
    Signed-off-by: Rusty Russell <ru...@rustcorp.com.au>
    (cherry picked from commit 8e518950ba281502318d6300f7a5ec6cdf6b5674)

commit 4c5589f6c7334445eb215025d98e12d48fde9cd3
Author: Rusty Russell <ru...@rustcorp.com.au>
Date:   Wed Jul 21 12:29:55 2010 +0930

    freeze: abort vacuuming when we're going to freeze.
    
    There are some reports of freeze timeouts, and it looks like vacuuming might
    be the culprit.  So we add code to tell them to abort when a freeze is
    going on.
    
    (This is based on the 1.0.112 branch version 517f05e42f, but far
     simpler since tdb is now robust against processes being killed during
     transaction commit)
    
    CQ:S1018154 & S1018349
    Signed-off-by: Rusty Russell <ru...@rustcorp.com.au>
    (cherry picked from commit f5d7dc679501e607c2c83a248a89d3cada9df146)

commit 7b45aa95c8c98991897905109090449318eaaea6
Author: Rusty Russell <ru...@rustcorp.com.au>
Date:   Mon Jul 26 13:58:48 2010 +0930

    takeover: prevent crash by avoiding free in traverse on RST timeout
    
    After 5 attempts to send a RST to a client without any response, we free
    "con"; this is done during a traverse.  This frees the node we are walking
    through (the node is made a child of "con" down in rb_tree.c's
    trbt_create_node() (Valgrind would catch this, as Martin confirmed).
    
    So, we create a temporary parent and reparent onto that; then we free
    that parent after the traverse, thus deleting the unwanted nodes.
    
    CQ:S1019041
    Signed-off-by: Rusty Russell <ru...@rustcorp.com.au>
    (cherry picked from commit 08f7f85477610a4916c1ec866aa467b28f1bbec3)

commit cbcf3b4983a63d52110e23cd97ffc8b612dc477c
Author: Ronnie Sahlberg <ronniesahlb...@gmail.com>
Date:   Wed Jul 20 12:21:33 2011 +1000

    ctdb: Add printing of the record flags when we are traversing a database to 
print its content.
    (based on commit 5eaa9a8683babac27f9f0144ff4cb5364fcd54f6)

commit 1a9e95992e6962b06ae9502391d10dd966dbd7ef
Author: Ronnie Sahlberg <ronniesahlb...@gmail.com>
Date:   Thu Apr 8 14:28:52 2010 +1000

    Fix a compiler warning
    (cherry picked from commit 8825a8e3936e4ddfc1482d07a63a620249f01fe7)

commit cc179bf2e72b6922a032a691fdb3e4e43ecb4386
Author: Volker Lendecke <v...@samba.org>
Date:   Wed Mar 24 10:35:10 2010 +0100

    In ctdb catdb, print the payload data length without the ctdb header length
    (cherry picked from commit 45b3fe253c1d00c571b351fc73415bc799df3083)

commit 500405bb626bef80e41662753853b940c0095da2
Author: Stefan Metzmacher <me...@samba.org>
Date:   Tue Sep 14 14:49:42 2010 +0200

    tools/ctdb: add 'persistent' flag to "ctdb attach"
    
    metze
    (cherry picked from commit 7a5790de22e8370b2812414aa1adef8201e8b269)

commit 000c4f89de401435be93d33abf109f0efc6c71f2
Author: Stefan Metzmacher <me...@samba.org>
Date:   Tue Sep 14 14:45:16 2010 +0200

    tools/ctdb: let "ctdb catdb" pass the persistent flag to ctdb_attach()
    
    metze
    (cherry picked from commit 4ec99c1eeab529865ac790ef554f3b099a14faf1)

commit 2b0cf32fe1494ca3aeb08a98c03b20a04c9be7ca
Author: Ronnie Sahlberg <ronniesahlb...@gmail.com>
Date:   Fri Aug 20 11:28:24 2010 +1000

    add a new commandline flag -v to enable verbose output
    (cherry picked from commit 96dd9f40f9464c3d9de98f1323568724a1e31dc9)

-----------------------------------------------------------------------

Summary of changes:
 client/ctdb_client.c       |   85 ++++-
 common/rb_tree.c           |   60 ++-
 common/rb_tree.h           |    9 +-
 config/events.d/README     |    2 +-
 doc/ctdb.1                 |  150 +++++---
 doc/ctdb.1.html            |  258 +++++++------
 doc/ctdb.1.xml             |  141 +++++---
 doc/ctdbd.1                |   41 ++-
 doc/ctdbd.1.html           |   84 ++--
 doc/ctdbd.1.xml            |    4 +-
 include/ctdb.h             |   12 +-
 include/ctdb_private.h     |   24 ++-
 packaging/RPM/ctdb.spec.in |   12 +-
 server/ctdb_call.c         |    2 +-
 server/ctdb_control.c      |    4 +
 server/ctdb_freeze.c       |    3 +
 server/ctdb_ltdb_server.c  |   25 +-
 server/ctdb_serverids.c    |   12 +-
 server/ctdb_takeover.c     |   17 +-
 server/ctdb_traverse.c     |   51 +++-
 server/ctdb_tunables.c     |   89 +++--
 server/ctdb_vacuum.c       |  897 ++++++++++++++++++++++++++++----------------
 tests/src/rb_test.c        |   39 ++-
 tools/ctdb.c               |   79 ++++-
 tools/ctdb_vacuum.c        |  439 +---------------------
 25 files changed, 1354 insertions(+), 1185 deletions(-)


Changeset truncated at 500 lines:

diff --git a/client/ctdb_client.c b/client/ctdb_client.c
index 2d3c176..94fc712 100644
--- a/client/ctdb_client.c
+++ b/client/ctdb_client.c
@@ -47,14 +47,13 @@ struct ctdb_req_header *_ctdbd_allocate_pkt(struct 
ctdb_context *ctdb,
        length = MAX(length, slength);
        size = (length+(CTDB_DS_ALIGNMENT-1)) & ~(CTDB_DS_ALIGNMENT-1);
 
-       hdr = (struct ctdb_req_header *)talloc_size(mem_ctx, size);
+       hdr = (struct ctdb_req_header *)talloc_zero_size(mem_ctx, size);
        if (hdr == NULL) {
                DEBUG(DEBUG_ERR,("Unable to allocate packet for operation %u of 
length %u\n",
                         operation, (unsigned)length));
                return NULL;
        }
        talloc_set_name_const(hdr, type);
-       memset(hdr, 0, slength);
        hdr->length       = length;
        hdr->operation    = operation;
        hdr->ctdb_magic   = CTDB_MAGIC;
@@ -1782,6 +1781,7 @@ struct traverse_state {
        uint32_t count;
        ctdb_traverse_func fn;
        void *private_data;
+       bool listemptyrecords;
 };
 
 /*
@@ -1811,7 +1811,9 @@ static void traverse_handler(struct ctdb_context *ctdb, 
uint64_t srvid, TDB_DATA
                return;
        }
 
-       if (data.dsize == sizeof(struct ctdb_ltdb_header)) {
+       if (!state->listemptyrecords &&
+           data.dsize == sizeof(struct ctdb_ltdb_header))
+       {
                /* empty records are deleted records in ctdb */
                return;
        }
@@ -1823,15 +1825,20 @@ static void traverse_handler(struct ctdb_context *ctdb, 
uint64_t srvid, TDB_DATA
        state->count++;
 }
 
-
-/*
-  start a cluster wide traverse, calling the supplied fn on each record
-  return the number of records traversed, or -1 on error
+/**
+ * start a cluster wide traverse, calling the supplied fn on each record
+ * return the number of records traversed, or -1 on error
+ *
+ * Extendet variant with a flag to signal whether empty records should
+ * be listed.
  */
-int ctdb_traverse(struct ctdb_db_context *ctdb_db, ctdb_traverse_func fn, void 
*private_data)
+static int ctdb_traverse_ext(struct ctdb_db_context *ctdb_db,
+                            ctdb_traverse_func fn,
+                            bool withemptyrecords,
+                            void *private_data)
 {
        TDB_DATA data;
-       struct ctdb_traverse_start t;
+       struct ctdb_traverse_start_ext t;
        int32_t status;
        int ret;
        uint64_t srvid = (getpid() | 0xFLL<<60);
@@ -1841,6 +1848,7 @@ int ctdb_traverse(struct ctdb_db_context *ctdb_db, 
ctdb_traverse_func fn, void *
        state.count = 0;
        state.private_data = private_data;
        state.fn = fn;
+       state.listemptyrecords = withemptyrecords;
 
        ret = ctdb_set_message_handler(ctdb_db->ctdb, srvid, traverse_handler, 
&state);
        if (ret != 0) {
@@ -1851,11 +1859,12 @@ int ctdb_traverse(struct ctdb_db_context *ctdb_db, 
ctdb_traverse_func fn, void *
        t.db_id = ctdb_db->db_id;
        t.srvid = srvid;
        t.reqid = 0;
+       t.withemptyrecords = withemptyrecords;
 
        data.dptr = (uint8_t *)&t;
        data.dsize = sizeof(t);
 
-       ret = ctdb_control(ctdb_db->ctdb, CTDB_CURRENT_NODE, 0, 
CTDB_CONTROL_TRAVERSE_START, 0,
+       ret = ctdb_control(ctdb_db->ctdb, CTDB_CURRENT_NODE, 0, 
CTDB_CONTROL_TRAVERSE_START_EXT, 0,
                           data, NULL, NULL, &status, NULL, NULL);
        if (ret != 0 || status != 0) {
                DEBUG(DEBUG_ERR,("ctdb_traverse_all failed\n"));
@@ -1876,6 +1885,18 @@ int ctdb_traverse(struct ctdb_db_context *ctdb_db, 
ctdb_traverse_func fn, void *
        return state.count;
 }
 
+/**
+ * start a cluster wide traverse, calling the supplied fn on each record
+ * return the number of records traversed, or -1 on error
+ *
+ * Standard version which does not list the empty records:
+ * These are considered deleted.
+ */
+int ctdb_traverse(struct ctdb_db_context *ctdb_db, ctdb_traverse_func fn, void 
*private_data)
+{
+       return ctdb_traverse_ext(ctdb_db, fn, false, private_data);
+}
+
 #define ISASCII(x) (isprint(x) && !strchr("\"\\", (x)))
 /*
   called on each key during a catdb
@@ -1883,7 +1904,8 @@ int ctdb_traverse(struct ctdb_db_context *ctdb_db, 
ctdb_traverse_func fn, void *
 int ctdb_dumpdb_record(struct ctdb_context *ctdb, TDB_DATA key, TDB_DATA data, 
void *p)
 {
        int i;
-       FILE *f = (FILE *)p;
+       struct ctdb_dump_db_context *c = (struct ctdb_dump_db_context *)p;
+       FILE *f = c->f;
        struct ctdb_ltdb_header *h = (struct ctdb_ltdb_header *)data.dptr;
 
        fprintf(f, "key(%u) = \"", (unsigned)key.dsize);
@@ -1899,15 +1921,36 @@ int ctdb_dumpdb_record(struct ctdb_context *ctdb, 
TDB_DATA key, TDB_DATA data, v
        fprintf(f, "dmaster: %u\n", h->dmaster);
        fprintf(f, "rsn: %llu\n", (unsigned long long)h->rsn);
 
-       fprintf(f, "data(%u) = \"", (unsigned)data.dsize);
-       for (i=sizeof(*h);i<data.dsize;i++) {
-               if (ISASCII(data.dptr[i])) {
-                       fprintf(f, "%c", data.dptr[i]);
-               } else {
-                       fprintf(f, "\\%02X", data.dptr[i]);
+       if (c->printlmaster && ctdb->vnn_map != NULL) {
+               fprintf(f, "lmaster: %u\n", ctdb_lmaster(ctdb, &key));
+       }
+
+       if (c->printhash) {
+               fprintf(f, "hash: 0x%08x\n", ctdb_hash(&key));
+               fprintf(f, "jenkins hash: 0x%08x\n", 
(uint32_t)tdb_jenkins_hash(&key));
+       }
+
+       if (c->printrecordflags) {
+               fprintf(f, "flags: 0x%08x", h->flags);
+               if (h->flags & CTDB_REC_FLAG_MIGRATED_WITH_DATA) printf(" 
MIGRATED_WITH_DATA");
+               if (h->flags & CTDB_REC_FLAG_VACUUM_MIGRATED) printf(" 
VACUUM_MIGRATED");
+               if (h->flags & CTDB_REC_FLAG_AUTOMATIC) printf(" AUTOMATIC");
+               fprintf(f, "\n");
+       }
+
+       if (c->printdatasize) {
+               fprintf(f, "data size: %u\n", (unsigned)data.dsize);
+       } else {
+               fprintf(f, "data(%u) = \"", (unsigned)(data.dsize - 
sizeof(*h)));
+               for (i=sizeof(*h);i<data.dsize;i++) {
+                       if (ISASCII(data.dptr[i])) {
+                               fprintf(f, "%c", data.dptr[i]);
+                       } else {
+                               fprintf(f, "\\%02X", data.dptr[i]);
+                       }
                }
+               fprintf(f, "\"\n");
        }
-       fprintf(f, "\"\n");
 
        fprintf(f, "\n");
 
@@ -1917,9 +1960,11 @@ int ctdb_dumpdb_record(struct ctdb_context *ctdb, 
TDB_DATA key, TDB_DATA data, v
 /*
   convenience function to list all keys to stdout
  */
-int ctdb_dump_db(struct ctdb_db_context *ctdb_db, FILE *f)
+int ctdb_dump_db(struct ctdb_db_context *ctdb_db,
+                struct ctdb_dump_db_context *ctx)
 {
-       return ctdb_traverse(ctdb_db, ctdb_dumpdb_record, f);
+       return ctdb_traverse_ext(ctdb_db, ctdb_dumpdb_record,
+                                ctx->printemptyrecords, ctx);
 }
 
 /*
diff --git a/common/rb_tree.c b/common/rb_tree.c
index b2c2ee8..bff7c5a 100644
--- a/common/rb_tree.c
+++ b/common/rb_tree.c
@@ -916,13 +916,20 @@ trbt_lookuparray32(trbt_tree_t *tree, uint32_t keylen, 
uint32_t *key)
 
 
 /* traverse a tree starting at node */
-static void 
+static int
 trbt_traversearray32_node(trbt_node_t *node, uint32_t keylen, 
-       void (*callback)(void *param, void *data), 
+       int (*callback)(void *param, void *data), 
        void *param)
 {
-       if (node->left) {
-               trbt_traversearray32_node(node->left, keylen, callback, param);
+       trbt_node_t *left = node->left;
+       trbt_node_t *right = node->right;
+
+       if (left) {
+               int ret;
+               ret = trbt_traversearray32_node(left, keylen, callback, param);
+               if (ret != 0) {
+                       return ret;
+               }
        }
 
        /* this is the smallest node in this subtree
@@ -930,35 +937,52 @@ trbt_traversearray32_node(trbt_node_t *node, uint32_t 
keylen,
           otherwise we must pull the next subtree and traverse that one as well
        */
        if (keylen == 0) {
-               callback(param, node->data);
+               int ret;
+
+               ret = callback(param, node->data);
+               if (ret != 0) {
+                       return ret;
+               }
        } else {
-               trbt_traversearray32(node->data, keylen, callback, param);
+               int ret;
+
+               ret = trbt_traversearray32(node->data, keylen, callback, param);
+               if (ret != 0) {
+                       return ret;
+               }
        }
 
-       if (node->right) {
-               trbt_traversearray32_node(node->right, keylen, callback, param);
+       if (right) {
+               int ret;
+
+               ret = trbt_traversearray32_node(right, keylen, callback, param);
+               if (ret != 0) {
+                       return ret;
+               }
        }
+
+       return 0;
 }
        
 
 /* traverse the tree using an array of uint32 as a key */
-void 
+int 
 trbt_traversearray32(trbt_tree_t *tree, uint32_t keylen, 
-       void (*callback)(void *param, void *data), 
+       int (*callback)(void *param, void *data), 
        void *param)
 {
        trbt_node_t *node;
 
        if (tree == NULL) {
-               return;
+               return 0;
        }
 
        node=tree->root;
        if (node == NULL) {
-               return;
+               return 0;
        }
 
-       trbt_traversearray32_node(node, keylen-1, callback, param);
+       return trbt_traversearray32_node(node, keylen-1, callback, param);
 }
 
 
@@ -999,7 +1023,7 @@ trbt_findfirstarray32(trbt_tree_t *tree, uint32_t keylen)
 }
 
 
-#if 0
+#if TEST_RB_TREE
 static void printtree(trbt_node_t *node, int levels)
 {
        int i;
@@ -1007,7 +1031,7 @@ static void printtree(trbt_node_t *node, int levels)
        printtree(node->left, levels+1);
 
        for(i=0;i<levels;i++)printf("    ");
-       printf("key:%d COLOR:%s (node:0x%08x parent:0x%08x left:0x%08x 
right:0x%08x)\n",node->key32,node->rb_color==TRBT_BLACK?"BLACK":"RED",(int)node,(int)node->parent,
 (int)node->left,(int)node->right);
+       printf("key:%d COLOR:%s (node:%p parent:%p left:%p 
right:%p)\n",node->key32,node->rb_color==TRBT_BLACK?"BLACK":"RED", node, 
node->parent, node->left, node->right);
 
        printtree(node->right, levels+1);
        printf("\n");
@@ -1021,13 +1045,11 @@ void print_tree(trbt_tree_t *tree)
        }
        printf("---\n");
        printtree(tree->root->left, 1);
-       printf("root node key:%d COLOR:%s (node:0x%08x left:0x%08x 
right:0x%08x)\n",tree->root->key32,tree->root->rb_color==TRBT_BLACK?"BLACK":"RED",(int)tree->root,(int)tree->root->left,(int)tree->root->right);
+       printf("root node key:%d COLOR:%s (node:%p left:%p 
right:%p)\n",tree->root->key32,tree->root->rb_color==TRBT_BLACK?"BLACK":"RED", 
tree->root, tree->root->left, tree->root->right);
        printtree(tree->root->right, 1);
        printf("===\n");
 }
-#endif
 
-# if 0
 void 
 test_tree(void)
 {
@@ -1037,7 +1059,7 @@ test_tree(void)
        int NUM=15;
        int cnt=0;
 
-       tree=trbt_create(talloc_new(NULL));
+       tree=trbt_create(talloc_new(NULL), 0);
 #if 0
        for(i=0;i<10;i++){
                printf("adding node %i\n",i);
diff --git a/common/rb_tree.h b/common/rb_tree.h
index cb7cba3..9846666 100644
--- a/common/rb_tree.h
+++ b/common/rb_tree.h
@@ -74,8 +74,13 @@ void trbt_insertarray32_callback(trbt_tree_t *tree, uint32_t 
keylen, uint32_t *k
    and return a pointer to data or NULL */
 void *trbt_lookuparray32(trbt_tree_t *tree, uint32_t keylen, uint32_t *key);
 
-/* Traverse a tree with a key based on an array of uint32 */
-void trbt_traversearray32(trbt_tree_t *tree, uint32_t keylen, void 
(*callback)(void *param, void *data), void *param);
+/* Traverse a tree with a key based on an array of uint32
+   returns 0 if traverse completed
+   !0 if the traverse was aborted
+
+   If the callback returns !0  the traverse will be aborted
+*/
+int trbt_traversearray32(trbt_tree_t *tree, uint32_t keylen, int 
(*callback)(void *param, void *data), void *param);
 
 /* Lookup the first node in the tree with a key based on an array of uint32 
    and return a pointer to data or NULL */
diff --git a/config/events.d/README b/config/events.d/README
index ef345b5..867529d 100644
--- a/config/events.d/README
+++ b/config/events.d/README
@@ -71,7 +71,7 @@ monitor
        The interval can be configured using the MonitorInterval tunable
        but defaults to 15 seconds.
 
-       This event is triggered by ctdb to continously monitor that all
+       This event is triggered by ctdb to continuously monitor that all
        managed services are healthy.
        When invoked, the event script will check that the service is healthy
        and return 0 if so. If the service is not healthy the event script
diff --git a/doc/ctdb.1 b/doc/ctdb.1
index 5e208e4..ffe8edc 100644
--- a/doc/ctdb.1
+++ b/doc/ctdb.1
@@ -1,13 +1,22 @@
 '\" t
 .\"     Title: ctdb
 .\"    Author: [FIXME: author] [see http://docbook.sf.net/el/author]
-.\" Generator: DocBook XSL Stylesheets v1.75.1 <http://docbook.sf.net/>
-.\"      Date: 02/24/2010
+.\" Generator: DocBook XSL Stylesheets v1.75.2 <http://docbook.sf.net/>
+.\"      Date: 01/12/2012
 .\"    Manual: CTDB - clustered TDB database
 .\"    Source: ctdb
 .\"  Language: English
 .\"
-.TH "CTDB" "1" "02/24/2010" "ctdb" "CTDB \- clustered TDB database"
+.TH "CTDB" "1" "01/12/2012" "ctdb" "CTDB \- clustered TDB database"
+.\" -----------------------------------------------------------------
+.\" * Define some portability stuff
+.\" -----------------------------------------------------------------
+.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+.\" http://bugs.debian.org/507673
+.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
+.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+.ie \n(.g .ds Aq \(aq
+.el       .ds Aq '
 .\" -----------------------------------------------------------------
 .\" * set default formatting
 .\" -----------------------------------------------------------------
@@ -24,7 +33,7 @@ ctdb \- clustered tdb database management utility
 .HP \w'\fBctdb\ [\ OPTIONS\ ]\ COMMAND\ \&.\&.\&.\fR\ 'u
 \fBctdb [ OPTIONS ] COMMAND \&.\&.\&.\fR
 .HP \w'\fBctdb\fR\ 'u
-\fBctdb\fR [\-n\ <node>] [\-Y] [\-t\ <timeout>] [\-T\ <timelimit>] [\-?\ 
\-\-help] [\-\-usage] [\-d\ \-\-debug=<INTEGER>] [\-\-socket=<filename>]
+\fBctdb\fR [\-n\ <node>] [\-Y] [\-t\ <timeout>] [\-T\ <timelimit>] [\-?\ 
\-\-help] [\-\-usage] [\-d\ \-\-debug=<INTEGER>] [\-\-socket=<filename>] 
[\-\-print\-emptyrecords] [\-\-print\-datasize] [\-\-print\-lmaster] 
[\-\-print\-hash] [\-\-print\-recordflags]
 .SH "DESCRIPTION"
 .PP
 ctdb is a utility to view and manage a ctdb cluster\&.
@@ -73,6 +82,31 @@ Specify the socketname to use when connecting to the local 
ctdb daemon\&. The de
 .sp
 You only need to specify this parameter if you run multiple ctdb daemons on 
the same physical host and thus can not use the default name for the domain 
socket\&.
 .RE
+.PP
+\-\-print\-emptyrecords
+.RS 4
+This enables printing of empty records when dumping databases with the catdb, 
cattbd and dumpdbbackup commands\&. Records with empty data segment are 
considered deleted by ctdb and cleaned by the vacuuming mechanism, so this 
switch can come in handy for debugging the vacuuming behaviour\&.
+.RE
+.PP
+\-\-print\-datasize
+.RS 4
+This lets database dumps (catdb, cattdb, dumpdbbackup) print the size of the 
record data instead of dumping the data contents\&.
+.RE
+.PP
+\-\-print\-lmaster
+.RS 4
+This lets catdb print the lmaster for each record\&.
+.RE
+.PP
+\-\-print\-hash
+.RS 4
+This lets database dumps (catdb, cattdb, dumpdbbackup) print the hash for each 
record\&.
+.RE
+.PP
+\-\-print\-recordflags
+.RS 4
+This lets catdb and dumpdbbackup print the record flags for each record\&. 
Note that cattdb always prints the flags\&.
+.RE
 .SH "ADMINISTRATIVE COMMANDS"
 .PP
 These are commands used to monitor and administrate a CTDB cluster\&.
@@ -407,12 +441,12 @@ Example output:
 .PP
 This command is used to disable an eventscript\&.
 .PP
-This will take effect the next time the eventscripts are being executed so it 
can take a short while until this is reflected in \'scriptstatus\'\&.
+This will take effect the next time the eventscripts are being executed so it 
can take a short while until this is reflected in \*(Aqscriptstatus\*(Aq\&.
 .SS "enablescript <script>"
 .PP
 This command is used to enable an eventscript\&.
 .PP
-This will take effect the next time the eventscripts are being executed so it 
can take a short while until this is reflected in \'scriptstatus\'\&.
+This will take effect the next time the eventscripts are being executed so it 
can take a short while until this is reflected in \*(Aqscriptstatus\*(Aq\&.
 .SS "getvar <name>"
 .PP
 Get the runtime value of a tuneable variable\&.
@@ -438,7 +472,7 @@ Set the runtime value of a tuneable variable\&.
 Example: ctdb setvar MaxRedirectCount 5
 .SS "listvars"
 .PP
-List all tuneable variables\&.
+List all tuneable variables, except the values of the obsolete tunables like 
VacuumMinInterval\&. The obsolete tunables can be retrieved only explicitly 
with the "ctdb getvar" command\&.
 .PP
 Example: ctdb listvars
 .PP
@@ -448,48 +482,44 @@ Example output:
 .RS 4
 .\}
 .nf
-MaxRedirectCount    = 3
-SeqnumInterval      = 1000
-ControlTimeout      = 60
-TraverseTimeout     = 20
-KeepaliveInterval   = 5
-KeepaliveLimit      = 5
-MaxLACount          = 7
-RecoverTimeout      = 20
-RecoverInterval     = 1
-ElectionTimeout     = 3
-TakeoverTimeout     = 5
-MonitorInterval     = 15
-TickleUpdateInterval = 20
-EventScriptTimeout  = 30
-EventScriptBanCount = 10
-EventScriptUnhealthyOnTimeout = 0
-RecoveryGracePeriod = 120
-RecoveryBanPeriod   = 300
-DatabaseHashSize    = 10000
-DatabaseMaxDead     = 5
-RerecoveryTimeout   = 10
-EnableBans          = 1
-DeterministicIPs    = 1
-DisableWhenUnhealthy = 0
-ReclockPingPeriod   = 60
-NoIPFailback        = 0
-VerboseMemoryNames  = 0
-RecdPingTimeout     = 60
-RecdFailCount       = 10
-LogLatencyMs        = 0
-RecLockLatencyMs    = 1000
-RecoveryDropAllIPs  = 60
-VerifyRecoveryLock  = 1
-VacuumDefaultInterval = 300
-VacuumMaxRunTime    = 30
-RepackLimit         = 10000
-VacuumLimit         = 5000
-VacuumMinInterval   = 60
-VacuumMaxInterval   = 600
-MaxQueueDropMsg     = 1000
-UseStatusEvents     = 0
-AllowUnhealthyDBRead = 0
+MaxRedirectCount        = 3
+SeqnumInterval          = 1000
+ControlTimeout          = 60
+TraverseTimeout         = 20
+KeepaliveInterval       = 5
+KeepaliveLimit          = 5
+RecoverTimeout          = 20
+RecoverInterval         = 1
+ElectionTimeout         = 3
+TakeoverTimeout         = 5
+MonitorInterval         = 15
+TickleUpdateInterval    = 20
+EventScriptTimeout      = 30
+EventScriptTimeoutCount = 1
+RecoveryGracePeriod     = 120
+RecoveryBanPeriod       = 300
+DatabaseHashSize        = 10000
+DatabaseMaxDead         = 5


-- 
CTDB repository

Reply via email to