[SCM] Samba Shared Repository - branch master updated

Amitay Isaacs amitay at samba.org
Fri Oct 4 07:08:02 UTC 2019


The branch, master has been updated
       via  2c54f6df716 ctdb-common: Mark VacuumLimit tunable as obsolete
       via  815ae644006 ctdb-vacuum: Drop debug level of repacking message to NOTICE
       via  a8c4e7d1f6b ctdb-protocol: Initialise request->rdata.opcode where missing
       via  33f1c9d9654 ctdb-vacuum: Process all records not deleted on a remote node
      from  fe41238097f rpcclient: Remove unused global domain sid

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 2c54f6df7164d6263624a1ed72485bf4e6690bb6
Author: Martin Schwenke <martin at meltin.net>
Date:   Wed Oct 2 17:52:31 2019 +1000

    ctdb-common: Mark VacuumLimit tunable as obsolete
    
    Use of this tunable was dropped over 5 years ago in commit
    16837bc309aa9a86fc21d7f59a8fce0b947428a3.
    
    Signed-off-by: Martin Schwenke <martin at meltin.net>
    Reviewed-by: Amitay Isaacs <amitay at gmail.com>
    
    Autobuild-User(master): Amitay Isaacs <amitay at samba.org>
    Autobuild-Date(master): Fri Oct  4 07:07:21 UTC 2019 on sn-devel-184

commit 815ae644006a11301c1ee81fdd4dcbf13de38141
Author: Martin Schwenke <martin at meltin.net>
Date:   Wed Oct 2 17:51:12 2019 +1000

    ctdb-vacuum: Drop debug level of repacking message to NOTICE
    
    This occurs rarely but can adversely impact performance, so it is
    worth logging it more frequently.
    
    Signed-off-by: Martin Schwenke <martin at meltin.net>
    Reviewed-by: Amitay Isaacs <amitay at gmail.com>

commit a8c4e7d1f6b3375e2cdac962133919cce91f7c1d
Author: Martin Schwenke <martin at meltin.net>
Date:   Mon Sep 23 16:11:00 2019 +1000

    ctdb-protocol: Initialise request->rdata.opcode where missing
    
    Otherwise it is uninitialised, so...
    
    ==22889== Conditional jump or move depends on uninitialised value(s)
    ==22889==    at 0x12257B: ctdb_req_control_data_len (protocol_control.c:39)
    ==22889==    by 0x1228E9: ctdb_req_control_len (protocol_control.c:1786)
    ==22889==    by 0x12A51C: ctdb_client_control_send (client_control.c:101)
    ==22889==    by 0x138BE1: ctdb_tunnel_setup_send (client_tunnel.c:100)
    ==22889==    by 0x10EE4F: tunnel_test_send (tunnel_test.c:135)
    ==22889==    by 0x10EE4F: main (tunnel_test.c:463)
    
    and similar.
    
    Signed-off-by: Martin Schwenke <martin at meltin.net>
    Reviewed-by: Amitay Isaacs <amitay at gmail.com>

commit 33f1c9d9654fbdcb99c23f9d23c4bbe2cc596b98
Author: Amitay Isaacs <amitay at gmail.com>
Date:   Mon Sep 30 16:34:35 2019 +1000

    ctdb-vacuum: Process all records not deleted on a remote node
    
    This currently skips the last record.
    
    BUG: https://bugzilla.samba.org/show_bug.cgi?id=14147
    RN: Avoid potential data loss during recovery after vacuuming error
    
    Signed-off-by: Amitay Isaacs <amitay at gmail.com>
    Reviewed-by: Martin Schwenke <martin at meltin.net>

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

Summary of changes:
 ctdb/common/tunable.c                     |  2 +-
 ctdb/doc/ctdb-tunables.7.xml              | 18 ------------------
 ctdb/doc/ctdb.1.xml                       |  1 -
 ctdb/doc/examples/config_migrate.sh       |  2 +-
 ctdb/protocol/protocol_client.c           |  4 ++++
 ctdb/server/ctdb_vacuum.c                 |  7 ++++---
 ctdb/tests/UNIT/tool/ctdb.listvars.001.sh |  1 -
 7 files changed, 10 insertions(+), 25 deletions(-)


Changeset truncated at 500 lines:

diff --git a/ctdb/common/tunable.c b/ctdb/common/tunable.c
index 8d475858c5f..70412b7f979 100644
--- a/ctdb/common/tunable.c
+++ b/ctdb/common/tunable.c
@@ -105,7 +105,7 @@ static struct {
 		offsetof(struct ctdb_tunable_list, vacuum_max_run_time) },
 	{ "RepackLimit", 10*1000, false,
 		offsetof(struct ctdb_tunable_list, repack_limit) },
-	{ "VacuumLimit", 5*1000, false,
+	{ "VacuumLimit", 5*1000, true,
 		offsetof(struct ctdb_tunable_list, vacuum_limit) },
 	{ "VacuumFastPathCount", 60, false,
 		offsetof(struct ctdb_tunable_list, vacuum_fast_path_count) },
diff --git a/ctdb/doc/ctdb-tunables.7.xml b/ctdb/doc/ctdb-tunables.7.xml
index 191bcaffe46..289b1d7324b 100644
--- a/ctdb/doc/ctdb-tunables.7.xml
+++ b/ctdb/doc/ctdb-tunables.7.xml
@@ -574,10 +574,6 @@ MonitorInterval=20
         <varname>RepackLimit</varname>, then the database is repacked
         to get rid of the freelist records to avoid fragmentation.
       </para>
-      <para>
-        Databases are repacked only if both <varname>RepackLimit</varname>
-        and <varname>VacuumLimit</varname> are exceeded.
-      </para>
     </refsect2>
 
     <refsect2>
@@ -683,20 +679,6 @@ MonitorInterval=20
       </para>
     </refsect2>
 
-    <refsect2>
-      <title>VacuumLimit</title>
-      <para>Default: 5000</para>
-      <para>
-        During vacuuming, if the number of deleted records are more than
-        <varname>VacuumLimit</varname>, then databases are repacked to
-        avoid fragmentation.
-      </para>
-      <para>
-        Databases are repacked only if both <varname>RepackLimit</varname>
-        and <varname>VacuumLimit</varname> are exceeded.
-      </para>
-    </refsect2>
-
     <refsect2>
       <title>VacuumMaxRunTime</title>
       <para>Default: 120</para>
diff --git a/ctdb/doc/ctdb.1.xml b/ctdb/doc/ctdb.1.xml
index 157dfad9dc1..e355752d1db 100644
--- a/ctdb/doc/ctdb.1.xml
+++ b/ctdb/doc/ctdb.1.xml
@@ -809,7 +809,6 @@ RecoveryDropAllIPs      = 120
 VacuumInterval          = 10
 VacuumMaxRunTime        = 120
 RepackLimit             = 10000
-VacuumLimit             = 5000
 VacuumFastPathCount     = 60
 MaxQueueDropMsg         = 1000000
 AllowUnhealthyDBRead    = 0
diff --git a/ctdb/doc/examples/config_migrate.sh b/ctdb/doc/examples/config_migrate.sh
index e0d01e77057..8983105f1c9 100755
--- a/ctdb/doc/examples/config_migrate.sh
+++ b/ctdb/doc/examples/config_migrate.sh
@@ -323,7 +323,6 @@ TickleUpdateInterval
 TraverseTimeout
 VacuumFastPathCount
 VacuumInterval
-VacuumLimit
 VacuumMaxRunTime
 VerboseMemoryNames
 EOF
@@ -336,6 +335,7 @@ check_removed_tunable ()
 
 	grep -Fiqx "$_tunable" <<EOF
 NoIPHostOnAllDisabled
+VacuumLimit
 EOF
 }
 
diff --git a/ctdb/protocol/protocol_client.c b/ctdb/protocol/protocol_client.c
index 9aa32a9bba7..a461ff36016 100644
--- a/ctdb/protocol/protocol_client.c
+++ b/ctdb/protocol/protocol_client.c
@@ -2311,6 +2311,8 @@ void ctdb_req_control_tunnel_register(struct ctdb_req_control *request,
 	request->srvid = tunnel_id;
 	request->client_id = 0;
 	request->flags = 0;
+
+	request->rdata.opcode = CTDB_CONTROL_TUNNEL_REGISTER;
 }
 
 int ctdb_reply_control_tunnel_register(struct ctdb_reply_control *reply)
@@ -2332,6 +2334,8 @@ void ctdb_req_control_tunnel_deregister(struct ctdb_req_control *request,
 	request->srvid = tunnel_id;
 	request->client_id = 0;
 	request->flags = 0;
+
+	request->rdata.opcode = CTDB_CONTROL_TUNNEL_DEREGISTER;
 }
 
 int ctdb_reply_control_tunnel_deregister(struct ctdb_reply_control *reply)
diff --git a/ctdb/server/ctdb_vacuum.c b/ctdb/server/ctdb_vacuum.c
index 0c3770267bc..c1015275fb0 100644
--- a/ctdb/server/ctdb_vacuum.c
+++ b/ctdb/server/ctdb_vacuum.c
@@ -814,7 +814,7 @@ static void ctdb_process_delete_list(struct ctdb_db_context *ctdb_db,
 		 */
 		records = (struct ctdb_marshall_buffer *)outdata.dptr;
 		rec = (struct ctdb_rec_data_old *)&records->data[0];
-		while (records->count-- > 1) {
+		while (records->count-- > 0) {
 			TDB_DATA reckey, recdata;
 			struct ctdb_ltdb_header *rechdr;
 			struct delete_record_data *dd;
@@ -1107,8 +1107,9 @@ static int ctdb_vacuum_and_repack_db(struct ctdb_db_context *ctdb_db,
 		return 0;
 	}
 
-	DEBUG(DEBUG_INFO, ("Repacking %s with %u freelist entries\n",
-			   name, freelist_size));
+	D_NOTICE("Repacking %s with %u freelist entries\n",
+		 name,
+		 freelist_size);
 
 	ret = tdb_repack(ctdb_db->ltdb->tdb);
 	if (ret != 0) {
diff --git a/ctdb/tests/UNIT/tool/ctdb.listvars.001.sh b/ctdb/tests/UNIT/tool/ctdb.listvars.001.sh
index a304942af43..88f0fa4daec 100755
--- a/ctdb/tests/UNIT/tool/ctdb.listvars.001.sh
+++ b/ctdb/tests/UNIT/tool/ctdb.listvars.001.sh
@@ -41,7 +41,6 @@ RecoveryDropAllIPs         = 120
 VacuumInterval             = 10
 VacuumMaxRunTime           = 120
 RepackLimit                = 10000
-VacuumLimit                = 5000
 VacuumFastPathCount        = 60
 MaxQueueDropMsg            = 1000000
 AllowUnhealthyDBRead       = 0


-- 
Samba Shared Repository



More information about the samba-cvs mailing list