1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-01 04:58:35 +03:00

merge from ronnie

(This used to be ctdb commit dd6cec4ed8cda0112120af3967dd06b9e7b9341b)
This commit is contained in:
Andrew Tridgell 2007-04-11 11:11:44 +10:00
commit a99a0470af
3 changed files with 22 additions and 9 deletions

View File

@ -180,5 +180,11 @@ struct ctdb_record_handle *ctdb_fetch_lock(struct ctdb_db_context *ctdb_db, TALL
*/
int ctdb_record_store(struct ctdb_record_handle *rec, TDB_DATA data);
/* when running in daemon mode this function is used by a client to tell
ctdb daemon what its local identifier is.
when in non-daemon mode this is a noop.
*/
int ctdb_register_message_local_id(struct ctdb_context *ctdb, uint32_t messenger_id);
#endif

View File

@ -190,13 +190,14 @@ struct ctdb_call_state {
operation IDs
*/
enum ctdb_operation {
CTDB_REQ_CALL = 0,
CTDB_REPLY_CALL = 1,
CTDB_REPLY_REDIRECT = 2,
CTDB_REQ_DMASTER = 3,
CTDB_REPLY_DMASTER = 4,
CTDB_REPLY_ERROR = 5,
CTDB_REQ_MESSAGE = 6
CTDB_REQ_CALL = 0,
CTDB_REPLY_CALL = 1,
CTDB_REPLY_REDIRECT = 2,
CTDB_REQ_DMASTER = 3,
CTDB_REPLY_DMASTER = 4,
CTDB_REPLY_ERROR = 5,
CTDB_REGISTER_CALL = 6,
CTDB_REQ_MESSAGE = 7
};
#define CTDB_MAGIC 0x43544442 /* CTDB */
@ -259,6 +260,12 @@ struct ctdb_reply_dmaster {
uint8_t data[1];
};
struct ctdb_register_call {
struct ctdb_req_header hdr;
uint32_t datalen;
uint8_t data[4];
};
struct ctdb_req_message {
struct ctdb_req_header hdr;
uint32_t srvid;

View File

@ -3,7 +3,7 @@
killall -q ctdb_bench
echo "Trying 2 nodes"
bin/ctdb_bench --nlist tests/nodes.txt --listen 127.0.0.2:9001 $* &
bin/ctdb_bench --nlist tests/nodes.txt --listen 127.0.0.1:9001 $*
bin/ctdb_bench --nlist tests/nodes.txt --listen 127.0.0.2:9001 --pid=55 $* &
bin/ctdb_bench --nlist tests/nodes.txt --listen 127.0.0.1:9001 --pid=66 $*
killall -q ctdb_bench