summaryrefslogtreecommitdiffstats
path: root/ctdb
diff options
context:
space:
mode:
Diffstat (limited to 'ctdb')
-rw-r--r--ctdb/Makefile.in6
-rw-r--r--ctdb/server/ctdb_recover.c5
2 files changed, 9 insertions, 2 deletions
diff --git a/ctdb/Makefile.in b/ctdb/Makefile.in
index 0dce3aa8187..0a2e58e5a94 100644
--- a/ctdb/Makefile.in
+++ b/ctdb/Makefile.in
@@ -53,7 +53,7 @@ CTDB_SERVER_OBJ = server/ctdbd.o server/ctdb_daemon.o server/ctdb_lockwait.o \
server/ctdb_serverids.o server/ctdb_persistent.o \
$(CTDB_CLIENT_OBJ) $(CTDB_TCP_OBJ) @INFINIBAND_WRAPPER_OBJ@
-TEST_BINS=bin/ctdb_bench bin/ctdb_fetch bin/ctdb_store bin/ctdb_persistent bin/rb_test \
+TEST_BINS=bin/ctdb_bench bin/ctdb_fetch bin/ctdb_store bin/ctdb_randrec bin/ctdb_persistent bin/rb_test \
@INFINIBAND_BINS@
BINS = bin/ctdb @CTDB_SCSI_IO@ bin/ctdb_ipmux bin/smnotify
@@ -126,6 +126,10 @@ bin/ctdb_store: $(CTDB_CLIENT_OBJ) tests/ctdb_store.o
@echo Linking $@
@$(CC) $(CFLAGS) -o $@ tests/ctdb_store.o $(CTDB_CLIENT_OBJ) $(LIB_FLAGS)
+bin/ctdb_randrec: $(CTDB_CLIENT_OBJ) tests/ctdb_randrec.o
+ @echo Linking $@
+ @$(CC) $(CFLAGS) -o $@ tests/ctdb_randrec.o $(CTDB_CLIENT_OBJ) $(LIB_FLAGS)
+
bin/ctdb_persistent: $(CTDB_CLIENT_OBJ) tests/ctdb_persistent.o
@echo Linking $@
@$(CC) $(CFLAGS) -o $@ tests/ctdb_persistent.o $(CTDB_CLIENT_OBJ) $(LIB_FLAGS)
diff --git a/ctdb/server/ctdb_recover.c b/ctdb/server/ctdb_recover.c
index 2acc190db40..c2b556bb101 100644
--- a/ctdb/server/ctdb_recover.c
+++ b/ctdb/server/ctdb_recover.c
@@ -332,6 +332,7 @@ int32_t ctdb_control_push_db(struct ctdb_context *ctdb, TDB_DATA indata)
if the rsn values are equal */
if (header.rsn < hdr->rsn ||
(header.dmaster != ctdb->pnn && header.rsn == hdr->rsn)) {
+#if 0
/* this is a push optimisation - we can skip writing the record if:
1) this is not a persistent db
@@ -344,7 +345,9 @@ int32_t ctdb_control_push_db(struct ctdb_context *ctdb, TDB_DATA indata)
header.dmaster != ctdb->pnn &&
hdr->dmaster != ctdb->pnn) {
DEBUG(5,("Skipping push of record\n"));
- } else {
+ } else
+#endif
+{
ret = ctdb_ltdb_store(ctdb_db, key, hdr, data);
if (ret != 0) {
DEBUG(0, (__location__ " Unable to store record\n"));