diff options
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/oplock.c | 6 | ||||
-rw-r--r-- | source3/smbd/server.c | 7 |
2 files changed, 13 insertions, 0 deletions
diff --git a/source3/smbd/oplock.c b/source3/smbd/oplock.c index 9f3679390b..ddb05d8b92 100644 --- a/source3/smbd/oplock.c +++ b/source3/smbd/oplock.c @@ -833,6 +833,9 @@ void share_mode_entry_to_message(char *msg, struct share_mode_entry *e) SIVAL(msg,44,e->share_file_id); SIVAL(msg,48,e->uid); SSVAL(msg,52,e->flags); +#ifdef CLUSTER_SUPPORT + SIVAL(msg,54,e->pid.vnn); +#endif } /**************************************************************************** @@ -853,6 +856,9 @@ void message_to_share_mode_entry(struct share_mode_entry *e, char *msg) e->share_file_id = (unsigned long)IVAL(msg,44); e->uid = (uint32)IVAL(msg,48); e->flags = (uint16)SVAL(msg,52); +#ifdef CLUSTER_SUPPORT + e->pid.vnn = IVAL(msg,54); +#endif } /**************************************************************************** diff --git a/source3/smbd/server.c b/source3/smbd/server.c index e95f3cf4a2..98b9fb8626 100644 --- a/source3/smbd/server.c +++ b/source3/smbd/server.c @@ -1112,6 +1112,13 @@ extern void build_options(BOOL screen); /* Setup aio signal handler. */ initialize_async_io_handler(); + /* + * For clustering, we need to re-init our ctdbd connection after the + * fork + */ + if (!NT_STATUS_IS_OK(messaging_reinit(smbd_messaging_context()))) + exit(1); + /* register our message handlers */ messaging_register(smbd_messaging_context(), NULL, MSG_SMB_FORCE_TDIS, msg_force_tdis); |