summaryrefslogtreecommitdiffstats
path: root/source3/lib/ctdbd_conn.c
Commit message (Collapse)AuthorAgeFilesLines
* lib/util: Remove obsolete sys_getpid() and sys_fork().Jelmer Vernooij2012-03-241-2/+2
| | | | | | | | | The performance of these is minimal (these days) and they can return invalid results when used as part of applications that do not use sys_fork(). Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Sat Mar 24 21:55:41 CET 2012 on sn-devel-104
* ctdb_conn: Avoid sys_connect.Jelmer Vernooij2012-03-241-1/+3
|
* s3-ctdb: Enable CTDB readonly support only if CTDB supports itAmitay Isaacs2012-03-051-1/+8
| | | | | Autobuild-User: Amitay Isaacs <amitay@samba.org> Autobuild-Date: Mon Mar 5 02:47:36 CET 2012 on sn-devel-104
* dbwrap_ctdb: only fetch a read-only copy if we had a record already.Rusty Russell2012-03-051-2/+3
| | | | | | | | | | | | | Because revoking read-only copies of records is expensive, we only want ctdbd to do it for high-turnover records. A basic heuristic is that if we don't find a local copy of the record, don't ask for a read-only copy. The fetch itself will cause ctdbd to migrate the record, so eventually we will have a local copy. Next time it gets migrated away, we'll call ctdbd_fetch() with local_copy = true. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* ctdbd_conn: fetch read-only copies of records.Rusty Russell2012-03-051-2/+2
| | | | | | | 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 <rusty@rustcorp.com.au>
* s3: Add SERVERID_UNIQUE_ID_NOT_TO_VERIFY, bug 8760Volker Lendecke2012-02-151-2/+9
| | | | | Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Wed Feb 15 21:10:22 CET 2012 on sn-devel-104
* s3: Increase debug level of basic ctdb packet handlingVolker Lendecke2012-02-071-6/+6
| | | | | | | | This clutters the debug level 10 output significantly without much value Autobuild-User: Volker Lendecke <vl@samba.org> Autobuild-Date: Tue Feb 7 18:19:08 CET 2012 on sn-devel-104
* s3: FreeBSD does not define sin6_addr.s_addr32Volker Lendecke2012-02-061-1/+1
| | | | | Autobuild-User: Volker Lendecke <vl@samba.org> Autobuild-Date: Mon Feb 6 20:03:58 CET 2012 on sn-devel-104
* s3:lib/ctdbd_conn: try ctdbd_init_connection() as rootStefan Metzmacher2011-12-231-0/+2
| | | | | | | | | | | ctdbd_traverse is only called if the main db_context is already open. So if we could get to information via dbwrap_fetch, we should also be able to traverse. metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Fri Dec 23 18:19:14 CET 2011 on sn-devel-104
* s3-ctdb: fix the build w/o HAVE_CTDB_CONTROL_CHECK_SRVIDS_DECLGünther Deschner2011-12-121-0/+4
| | | | | | | | | Volker, please check. Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Mon Dec 12 17:42:29 CET 2011 on sn-devel-104
* s3-ctdb: Make use of CTDB_CONTROL_CHECK_SRVIDSVolker Lendecke2011-11-301-2/+210
| | | | | | | | This should be a lot quicker than PROCESS_EXISTS followed by looking at serverid.tdb Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Wed Nov 30 12:47:27 CET 2011 on sn-devel-104
* s3: server_id.pid has turned 64 (bits, that is)Volker Lendecke2011-11-101-4/+11
| | | | | | | | Fix ctdb_processes_exist protocol. The socket expects pid_t which is 32 bits on 32 bit machines. Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Thu Nov 10 18:57:01 CET 2011 on sn-devel-104
* s3-ctdb: Fix ctdb_read_reqVolker Lendecke2011-10-271-23/+17
| | | | | | | | | If a complete request has come in already before we consumed it, the ctdb_packet_fd_read_sync will block indefinitely. So always try packet_handler first and only if that fails due to insufficient data, read from the socket. Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Thu Oct 27 22:12:05 CEST 2011 on sn-devel-104
* s3-ctdb: Add debug to ctdb_processes_existVolker Lendecke2011-10-271-0/+6
|
* s3-ctdb: Make ctdbd_process_exists use ctdbd_processes_existVolker Lendecke2011-10-271-13/+8
| | | | Not strictly necessary, but more code exercise is good
* s3-ctdb: Add ctdb_processes_existVolker Lendecke2011-10-271-0/+98
| | | | | This sends out a number of process_exists controls in parallel and collects the replies as they come in.
* s3-ctdb: Allow ctdb_read_req to read any reqidVolker Lendecke2011-10-271-1/+1
|
* s3-ctdb: Don't hand out 0 as reqidVolker Lendecke2011-10-271-4/+13
| | | | 0 will be used as a wildcard reqid in ctdb_read_req
* s3: Fix some type-punned warningsVolker Lendecke2011-10-271-4/+4
|
* s3: Silence some warningsVolker Lendecke2011-08-301-0/+19
| | | | | | | | | | | Rusty, please suggest a proper fix for this. Thanks, Volker Lendecke Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Tue Aug 30 19:16:14 CEST 2011 on sn-devel-104
* s3: Remove a bogus commentVolker Lendecke2011-08-251-4/+0
|
* s3-talloc Change TALLOC_ZERO_P() to talloc_zero()Andrew Bartlett2011-06-091-1/+1
| | | | | Using the standard macro makes it easier to move code into common, as TALLOC_ZERO_P isn't standard talloc.
* s3-talloc Change TALLOC_P() to talloc()Andrew Bartlett2011-06-091-2/+2
| | | | | Using the standard macro makes it easier to move code into common, as TALLOC_P isn't standard talloc.
* Fix Bug 8152 - smbd crash in release_ip()Christian Ambach2011-05-191-0/+5
| | | | | | | | release_ip() needs the private_data, but it was never saved away to feed it into release_ip() later Autobuild-User: Christian Ambach <ambi@samba.org> Autobuild-Date: Thu May 19 21:21:14 CEST 2011 on sn-devel-104
* s3: only include tdb headers where needed.Günther Deschner2011-05-061-0/+1
| | | | Guenther
* s3-ctdb Fix duplicate function name due to packet -> ctdb_packet rename.Andrew Bartlett2011-05-031-1/+1
| | | | Signed-off-by: Günther Deschner <gd@samba.org>
* s3-ctdb Rename packet file and files to ctdb_packetAndrew Bartlett2011-05-031-29/+29
| | | | | | | This avoids a conflicts with the Samba4 packet.c, as these is only used in CTDB Andrew Bartlett
* s3:ctdb: pass the ctdb control flags to the ctdb daemon when sending the controlMichael Adam2011-03-311-0/+1
| | | | | | The only flag that is currently used is the NOREPLY flag to indicate that the client expects no reply packet. This needs to get passed down to the ctdb daemon so that it really does not send a reply.
* s3:ctdb: samba can now handle the NOREPLY flagMichael Adam2011-03-311-3/+0
| | | | | | Revert "samba3 can't handle NOREPLY yet" This reverts commit 9bf211db6d7d6ef6e59508de69d6d8dfe5bae059.
* s3:ctdb: correctly handle cstatus if CTDB_CTRL_FLAG_NOREPLY is set.Michael Adam2011-03-311-0/+3
|
* s3-messages: make ndr_messaging.h part of messages.h.Günther Deschner2011-03-301-2/+0
| | | | Guenther
* s3-messages: only include messages.h where needed.Günther Deschner2011-03-301-0/+1
| | | | Guenther
* s3-packet: only include packet.h where needed.Günther Deschner2011-03-161-0/+1
| | | | Guenther
* s3: Eliminate select from packet_fd_read_syncVolker Lendecke2011-02-281-6/+5
|
* s3: Remove superfluous ;Günther Deschner2011-02-021-1/+1
| | | | | | | Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Wed Feb 2 15:44:21 CET 2011 on sn-devel-104
* s3: Fix the code to immediately disconnect from a non-working ctdbdVolker Lendecke2011-01-211-0/+1
|
* s3: Do not connect to ctdb if it is blocked for some reasonVolker Lendecke2010-11-021-0/+58
|
* cluster_fatal() exit code should not indicate success.Martin Schwenke2010-11-021-1/+1
| | | | | | | | | | cluster_fatal() logs a fatal event and then exits with 0. This seems wrong. Sometimes command like "net" use this code and return incorrect empty output but then exit with 0. This simply changes the exit code to 1. Signed-off-by: Martin Schwenke <martin@meltin.net>
* s3: Pass tdb_flags to ctdbd when attaching to a dbVolker Lendecke2010-10-261-1/+1
| | | | This is required to make ctdb create databases with INCOMPATIBLE_HASH
* s3: Remove talloc_autofree_context() from ctdb_read_req()Volker Lendecke2010-09-261-1/+2
|
* s3-build: only include ctdbd_conn.h where needed.Günther Deschner2010-09-201-0/+1
| | | | Guenther
* s3-ctdb: ctdbd_init_connection() is static to this file.Günther Deschner2010-09-011-8/+0
| | | | Guenther
* s3: Make ctdbd_init_connection staticVolker Lendecke2010-08-311-2/+2
|
* s3: Remove procid_self() from ctdb_read_req() and ctdb_handle_message()Volker Lendecke2010-07-051-4/+8
|
* s3: Remove some type-punned warningsVolker Lendecke2010-07-051-5/+5
|
* s3-build: fix the build.Günther Deschner2010-05-181-2/+2
| | | | Guenther
* s3:ctdb_conn: add ctdbd_conn_get_fd() to get the fd out of the ctdb connectionMichael Adam2010-02-121-0/+5
| | | | Michael
* s3: Add ctdb_conn_msg_ctx()Volker Lendecke2010-02-121-0/+5
|
* s3: Implement global locks in a g_lock tdbVolker Lendecke2010-02-121-5/+68
| | | | | | This is the basis to implement global locks in ctdb without depending on a shared file system. The initial goal is to make ctdb persistent transactions deterministic without too many timeouts.
* s3-brlock: we don't need these MSG_SMB_UNLOCK calls nowAndrew Tridgell2010-02-051-8/+0
| | | | These have been replaced with the min timeout in blocking.c