From 67bb5abe81dc64758a792060673b923cd77a018a Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Fri, 3 Feb 2012 10:54:53 +1100 Subject: ctdbd_conn: fetch read-only copies of records. This means we try to get a read-only copy of a record, which we can then place in the local tdb. Signed-off-by: Rusty Russell --- source3/lib/ctdbd_conn.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source3/lib/ctdbd_conn.c b/source3/lib/ctdbd_conn.c index 9c73002078..f160fd6151 100644 --- a/source3/lib/ctdbd_conn.c +++ b/source3/lib/ctdbd_conn.c @@ -1391,7 +1391,7 @@ NTSTATUS ctdbd_migrate(struct ctdbd_connection *conn, uint32 db_id, } /* - * remotely fetch a record without locking it or forcing a migration + * remotely fetch a record (read-only) */ NTSTATUS ctdbd_fetch(struct ctdbd_connection *conn, uint32 db_id, TDB_DATA key, TALLOC_CTX *mem_ctx, TDB_DATA *data) @@ -1407,7 +1407,7 @@ NTSTATUS ctdbd_fetch(struct ctdbd_connection *conn, uint32 db_id, req.hdr.ctdb_version = CTDB_VERSION; req.hdr.operation = CTDB_REQ_CALL; req.hdr.reqid = ctdbd_next_reqid(conn); - req.flags = 0; + req.flags = CTDB_WANT_READONLY; req.callid = CTDB_FETCH_FUNC; req.db_id = db_id; req.keylen = key.dsize; -- cgit