summaryrefslogtreecommitdiffstats
path: root/source3/lib/ctdbd_conn.c
Commit message (Collapse)AuthorAgeFilesLines
* smbd/winbindd: Do an early check if ctdbd is functionalVolker Lendecke2013-10-171-0/+24
| | | | | | | | | This will avoid panic calls when smbd and winbind is started in cluster mode before ctdb is functional. It still logs something sane at debug level 0, but it does not panic and core anymore. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* ctdbd_conn: Remove one call to cluster_fatalVolker Lendecke2013-10-171-1/+0
| | | | | | | | This is during startup of a ctdb connection, thus it is not as important as in other cases to immediately exit to free up resources Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* ctdbd_conn: Remove one call to cluster_fatalVolker Lendecke2013-10-171-1/+2
| | | | | | | | This is during startup of a ctdb connection, thus it is not as important as in other cases to immediately exit to free up resources Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* ctdbd_conn: Lift the cluster_fatal call in get_cluster_vnnVolker Lendecke2013-10-171-1/+3
| | | | | | | We have to report a proper error when ctdbd is not around Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* dbwrap_ctdb: Treat empty records as non-existingVolker Lendecke2013-08-281-0/+8
| | | | | | | | | This is a patch implementing the workaround Christian mentioned in https://bugzilla.samba.org/show_bug.cgi?id=10008#c5 Bug: https://bugzilla.samba.org/show_bug.cgi?id=10008 Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Christian Ambach <ambi@samba.org>
* libctdb: Avoid an explicit memsetVolker Lendecke2013-08-161-2/+1
| | | | | | | | | | Give the compiler a chance to use better code. Saves a few bytes of text. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Aug 16 01:51:55 CEST 2013 on sn-devel-104
* ctdb-conn: remove ctdbd_fetchVolker Lendecke2013-03-261-81/+0
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* ctdb-conn: Add ctdbd_parseVolker Lendecke2013-03-261-0/+71
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* s3:lib: s/event_add_timed/tevent_add_timerStefan Metzmacher2013-02-191-1/+1
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:lib: s/event_add_fd/tevent_add_fd and s/EVENT_FD_/TEVENT_FD_Stefan Metzmacher2013-02-191-2/+2
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:lib: s/struct fd_event/struct tevent_fdStefan Metzmacher2013-02-191-2/+2
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:lib: s/struct timed_event/struct tevent_timerStefan Metzmacher2013-02-191-2/+2
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:lib: s/struct event_context/struct tevent_contextStefan Metzmacher2013-02-191-2/+2
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3-ctdb: Make sure addr.sun_path is null terminated.Andreas Schneider2012-12-121-1/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Günther Deschner <gd@samba.org>
* s3-ctdb: return proper exit codeChristian Ambach2012-08-031-1/+1
| | | | | | | do not loose the result from ctdbd_messaging_send_blob() Autobuild-User(master): Christian Ambach <ambi@samba.org> Autobuild-Date(master): Fri Aug 3 14:49:01 CEST 2012 on sn-devel-104
* s3-ctdb: adjust a loglevelChristian Ambach2012-08-031-2/+2
|
* s3-ctdb: Fix ctdb_serverids_exist for target nodes that diedVolker Lendecke2012-08-031-4/+20
| | | | Signed-off-by: Christian Ambach <ambi@samba.org>
* s3-ctdb: Add debugs to ctdb_serverids_existVolker Lendecke2012-08-031-10/+20
| | | | Signed-off-by: Christian Ambach <ambi@samba.org>
* s3:ctdbd_conn: use unitX_t types consistently throughout the moduleMichael Adam2012-08-011-22/+22
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* s3: Use string_term_tdb_data where appropriateVolker Lendecke2012-06-211-2/+1
| | | | Signed-off-by: Michael Adam <obnox@samba.org>
* s3: Fix const warningsVolker Lendecke2012-06-211-2/+3
| | | | Signed-off-by: Michael Adam <obnox@samba.org>
* s3: Make ctdbd_messaging_send_blob available in non-clustered modeVolker Lendecke2012-04-171-1/+10
| | | | This will avoid the need for some #ifdefs
* s3: Introduce ctdb_messaging_send_blobVolker Lendecke2012-04-171-20/+20
| | | | Send a raw blob without the messaging.idl wrap
* s3: Return CTDB_PATH from lp_ctdbd_socket()Volker Lendecke2012-04-171-4/+0
| | | | All callers had that fallback
* 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>