]> git.ipfire.org Git - thirdparty/samba.git/log
thirdparty/samba.git
18 years agomake sure we notify ctdb when a node dies
Andrew Tridgell [Tue, 17 Apr 2007 09:41:29 +0000 (19:41 +1000)] 
make sure we notify ctdb when a node dies
(This used to be ctdb commit 598feb4fb9badcf329837965ad39e0f0dfe28498)

18 years agomerge from volker and ronnie
Andrew Tridgell [Tue, 17 Apr 2007 09:27:49 +0000 (19:27 +1000)] 
merge from volker and ronnie
(This used to be ctdb commit ccc3bef713598f7df6d2e5d83618038d5f25fd68)

18 years agomerge from volker to prevent some valgrind errors
Ronnie sahlberg [Tue, 17 Apr 2007 08:15:08 +0000 (18:15 +1000)] 
merge from volker to prevent some valgrind errors

(This used to be ctdb commit ab516a6dcc6871cdbf781892adcd2c77e4c631c2)

18 years agomerge from tridge
Ronnie sahlberg [Tue, 17 Apr 2007 07:38:49 +0000 (17:38 +1000)] 
merge from tridge

(This used to be ctdb commit cf0948e73a10d7bc402a4ade4d9a87a7a247bdba)

18 years agoZERO_STRUCT writes one byte too many here.
Volker Lendecke [Tue, 17 Apr 2007 07:36:53 +0000 (09:36 +0200)] 
ZERO_STRUCT writes one byte too many here.
(This used to be ctdb commit 3c5c433e5b92f8fe2193a6e5720e31e3eb6bc76b)

18 years agoupdate destination in a redirect reply
Andrew Tridgell [Tue, 17 Apr 2007 07:11:12 +0000 (17:11 +1000)] 
update destination in a redirect reply
(This used to be ctdb commit b2836974ad270e823c630e3acf12327b53c37d88)

18 years agostop the client looping (temporary measure)
Andrew Tridgell [Tue, 17 Apr 2007 07:10:50 +0000 (17:10 +1000)] 
stop the client looping (temporary measure)
(This used to be ctdb commit 8e6a25f4c4a63145c0dee33453a0693dd395ee68)

18 years agostart using ctdb_ltdb_lock_fetch_requeue()
Andrew Tridgell [Tue, 17 Apr 2007 06:54:03 +0000 (16:54 +1000)] 
start using ctdb_ltdb_lock_fetch_requeue()
(This used to be ctdb commit f89ab3a06b4677f56c92768c3a8ae5ec9f5abbc2)

18 years agomerge from tridge
Ronnie sahlberg [Tue, 17 Apr 2007 06:43:53 +0000 (16:43 +1000)] 
merge from tridge

(This used to be ctdb commit 268a89db5886955e290538fdc08d3e94172e3527)

18 years agowhen we get a lmaster request, skip updating the header when we are also the new...
Andrew Tridgell [Tue, 17 Apr 2007 06:35:28 +0000 (16:35 +1000)] 
when we get a lmaster request, skip updating the header when we are also the new dmaster
(This used to be ctdb commit 6c48dcc5df7b855fc8e0774c9572c7b2af618348)

18 years agowe should not lock in a normal ctdb_call(), as we want them to run concurrently
Andrew Tridgell [Tue, 17 Apr 2007 06:34:53 +0000 (16:34 +1000)] 
we should not lock in a normal ctdb_call(), as we want them to run concurrently
(This used to be ctdb commit f4c8c4b3d4c6fb8f1b8e770d1788816af74a7e1f)

18 years ago- send the record header from the client to the daemon when doing a
Andrew Tridgell [Tue, 17 Apr 2007 06:20:32 +0000 (16:20 +1000)] 
- send the record header from the client to the daemon when doing a
  fetch, to avoid the daemon re-reading it

- suffix the database name with the node name so that testing on
  loopback doesn't result in a name collision in the database open

(This used to be ctdb commit ad30a4db75450643ff146c40faa306a021de3dd2)

18 years agomerge from tridge
Ronnie sahlberg [Tue, 17 Apr 2007 05:35:06 +0000 (15:35 +1000)] 
merge from tridge

(This used to be ctdb commit c4531b6de9189c3cd80862e29d2dd37aab36b9b4)

18 years agomake sure we unlock
Andrew Tridgell [Tue, 17 Apr 2007 05:33:58 +0000 (15:33 +1000)] 
make sure we unlock
(This used to be ctdb commit c09054f878a88129abb6cce24c7bbf53f61a2648)

18 years agoblock SIGPIPE in the daemon to prevent a SIGPIPE on write to a dead socket
Andrew Tridgell [Tue, 17 Apr 2007 05:33:20 +0000 (15:33 +1000)] 
block SIGPIPE in the daemon to prevent a SIGPIPE on write to a dead socket
(This used to be ctdb commit 02c09dc07c9bed57ca3692b14e41ac8cca0a29f4)

18 years agonow that both daemon and client access the database, it needs to be a real disk file
Andrew Tridgell [Tue, 17 Apr 2007 05:32:49 +0000 (15:32 +1000)] 
now that both daemon and client access the database, it needs to be a real disk file
(This used to be ctdb commit 5159f3a61f41bbaf563edd8d901a6bf5bfee4e4e)

18 years agomerge from tridge
Ronnie sahlberg [Tue, 17 Apr 2007 05:02:20 +0000 (15:02 +1000)] 
merge from tridge

(This used to be ctdb commit e1ea91fa541a21c8164b8bd26b9c77053e8487cb)

18 years agotidyups in test code
Andrew Tridgell [Tue, 17 Apr 2007 05:01:42 +0000 (15:01 +1000)] 
tidyups in test code
(This used to be ctdb commit 43061a4cf9b0995ebe6c86e27f7fc3aacb7bb23e)

18 years ago- removed the non-daemon mode from ctdb, in order to simplify the
Andrew Tridgell [Tue, 17 Apr 2007 04:52:51 +0000 (14:52 +1000)] 
- removed the non-daemon mode from ctdb, in order to simplify the
  code. It may be added back later once everything is working nicely,
  or simulated using a in-process pipe instead of a unix domain socket

- rewrote the ctdb_fetch_lock() code to follow the new design

(This used to be ctdb commit 5024dd1f305fe1ecc262db2240c56f773b4f28f0)

18 years agomerge from ronnie
Andrew Tridgell [Tue, 17 Apr 2007 02:53:04 +0000 (12:53 +1000)] 
merge from ronnie
(This used to be ctdb commit e4ab90e741bfb6b0bb88abb818fe036475cdd0f6)

18 years agocreate symbols for fetch lock response status
Ronnie sahlberg [Tue, 17 Apr 2007 02:42:52 +0000 (12:42 +1000)] 
create symbols for fetch lock response status

(This used to be ctdb commit d8243f474897dc65fb7286225b07bdf48b6faed0)

18 years agofinalize fetch lock changes to get rid of the record handle
Ronnie sahlberg [Tue, 17 Apr 2007 02:36:31 +0000 (12:36 +1000)] 
finalize fetch lock changes to get rid of the record handle

(This used to be ctdb commit 36c1e98a5533214d5507699dc5d8bdec35cb28c2)

18 years agodo not use a ctdb_record_handle for client fetch_lock/store_unlock any more
Ronnie sahlberg [Tue, 17 Apr 2007 02:22:17 +0000 (12:22 +1000)] 
do not use a ctdb_record_handle for client fetch_lock/store_unlock any more

change ctdb_client_fetch_lock to return a status code instead of a record handle and make it unconditionally fill in data.

change ctdb_client_store_unlock to take ctdb_db and key as arguments instead of a record handle

update the ctdb_fetch.c test to use the clientside helpers for fetching and storing data

(This used to be ctdb commit 22d5d40375e0135916c97945646f94119612615d)

18 years agomerge from ronnie
Andrew Tridgell [Tue, 17 Apr 2007 01:54:19 +0000 (11:54 +1000)] 
merge from ronnie
(This used to be ctdb commit d854392b04c46bcdd008cced5d16a03d81f97bd0)

18 years agoremaning code to finish lock_fetch/store_unlock clientside helpers
Ronnie sahlberg [Tue, 17 Apr 2007 01:48:27 +0000 (11:48 +1000)] 
remaning code to finish lock_fetch/store_unlock clientside helpers

(This used to be ctdb commit edf1e1fea8500461a08cd2795251a5cc0bd10229)

18 years agoinitial change to remove store_unlock pdu and use tdb chainlock in the client
Ronnie sahlberg [Tue, 17 Apr 2007 01:34:45 +0000 (11:34 +1000)] 
initial change to remove store_unlock pdu and use tdb chainlock in the client

(This used to be ctdb commit 87dd265d2c61125ca2fa922cfcf9371a234fff0c)

18 years agomerge from ronnie
Andrew Tridgell [Tue, 17 Apr 2007 01:30:19 +0000 (11:30 +1000)] 
merge from ronnie
(This used to be ctdb commit fcf3669c27691ddb383d1c585234622efa498d90)

18 years agopartial merge from volker (some overlaps removed)
Andrew Tridgell [Tue, 17 Apr 2007 01:26:59 +0000 (11:26 +1000)] 
partial merge from volker (some overlaps removed)

(This used to be ctdb commit c4747460a8e0017acfd2a97a632ecd9395562d4f)

18 years agobetter error handling in ctdb_ltdb_lock_fetch_requeue()
Andrew Tridgell [Tue, 17 Apr 2007 01:20:00 +0000 (11:20 +1000)] 
better error handling in ctdb_ltdb_lock_fetch_requeue()
(This used to be ctdb commit 1952be19f625dbe257050acebf468e7e6eb0da8c)

18 years agochange some error printouts to make it easier to determine whether the error occured...
Ronnie sahlberg [Tue, 17 Apr 2007 00:15:44 +0000 (10:15 +1000)] 
change some error printouts to make it easier to determine whether the error occured in the client or in the daemon

(This used to be ctdb commit a7e42c2c56e38b4b58ede0ad45767695d704dac4)

18 years agomerge from tridge
Ronnie sahlberg [Mon, 16 Apr 2007 23:37:13 +0000 (09:37 +1000)] 
merge from tridge

(This used to be ctdb commit 1000ea33025b625e23e7065f95efad447c380c8c)

18 years agoadd an explanation of ctdb_ltdb_lock_fetch_requeue()
Andrew Tridgell [Mon, 16 Apr 2007 23:18:20 +0000 (09:18 +1000)] 
add an explanation of ctdb_ltdb_lock_fetch_requeue()
(This used to be ctdb commit 7c749315130a2bc87dcc07460d10dcb089ae4202)

18 years agoadd an explanation of how to use ctdb_lockwait()
Andrew Tridgell [Mon, 16 Apr 2007 23:14:52 +0000 (09:14 +1000)] 
add an explanation of how to use ctdb_lockwait()
(This used to be ctdb commit e0c9844ea6270ff506b0b5906aa6ccfcc3bcce7a)

18 years agofixed crash bug - thanks volker
Andrew Tridgell [Mon, 16 Apr 2007 23:10:52 +0000 (09:10 +1000)] 
fixed crash bug - thanks volker
(This used to be ctdb commit e293f6fadf673d8bc7203198d709bcb28c26b482)

18 years agodarn, forgot this
Andrew Tridgell [Mon, 16 Apr 2007 21:41:27 +0000 (07:41 +1000)] 
darn, forgot this
(This used to be ctdb commit 0feb5da60c0331f6c391622910ca1f436263ce46)

18 years agowait on the right fd ....
Andrew Tridgell [Mon, 16 Apr 2007 14:11:04 +0000 (00:11 +1000)] 
wait on the right fd ....
(This used to be ctdb commit 27b67ee6576b17f8b3aae024ae3bd0bb1c42f0f2)

18 years agoadded a ctdb_ltdb_lock_fetch_requeue() function
Andrew Tridgell [Mon, 16 Apr 2007 13:52:14 +0000 (23:52 +1000)] 
added a ctdb_ltdb_lock_fetch_requeue() function
this will be the core of the non-blocking lock idea for ctdb, it will be used
in place of ctdb_ltdb_fetch(), but will also get a lock. It re-starts a request
if it needs to block
(This used to be ctdb commit afa479026cf6293e6a878c8a329cdac035284672)

18 years agoadded a tdb_chainlock_nonblock() call to tdb
Andrew Tridgell [Mon, 16 Apr 2007 13:03:36 +0000 (23:03 +1000)] 
added a tdb_chainlock_nonblock() call to tdb
(This used to be ctdb commit 6587bdca71d97709c9271a73aea0be5a2a35f399)

18 years agomerge local copy of tdb from samba4 tdb
Andrew Tridgell [Mon, 16 Apr 2007 12:52:58 +0000 (22:52 +1000)] 
merge local copy of tdb from samba4 tdb
(This used to be ctdb commit d4619ce98ce44acaebeb6ae9c516a7917bf4e27f)

18 years agofixed a fd bug (thanks volker)
Andrew Tridgell [Mon, 16 Apr 2007 12:49:37 +0000 (22:49 +1000)] 
fixed a fd bug (thanks volker)
(This used to be ctdb commit 512a96de1b31e856785749ffc0bed60b1c589f9e)

18 years agomerge from tridge
Ronnie sahlberg [Mon, 16 Apr 2007 06:03:08 +0000 (16:03 +1000)] 
merge from tridge

(This used to be ctdb commit 7e60f4ea41707b064e646d0271e81a18f5640aba)

18 years agothis is a demonstration of an idea for handling locks in ctdb.
Andrew Tridgell [Mon, 16 Apr 2007 06:01:37 +0000 (16:01 +1000)] 
this is a demonstration of an idea for handling locks in ctdb.

The problem we have is this:

  - we want the client smbd processes to be able to 'shortcut' access
    to the ltdb, by directly accessing the ltdb, and if the header of
    the record shows we are the dmaster then process immediately, with
    no overhead of talking across the unix domain socket

  - a client doing a shortcut will use tdb_chainlock() to lock the
    record while processing

  - we want the main ctdb daemon to be able to set locks on the
    record, and when those locks collide with a 'shortcut' fcntl lock,
    we want the ctdb daemon to keep processing other operations

  - we don't want to have to send a message from a smbd client to the
    ctdbd each time it releases a lock

The solution is shown in this example. Note that the expensive fork()
and blocking lock is only paid in case of contention, so in the median
case I think this is zero cost.

(This used to be ctdb commit a3248c3e2b740cd2403acffd3c1f6a33dca0ea03)

18 years agomerge from tridge
Ronnie sahlberg [Mon, 16 Apr 2007 04:45:09 +0000 (14:45 +1000)] 
merge from tridge

(This used to be ctdb commit 014a255f5e8d97d296d2fe061ab9c2c25494076d)

18 years agomerged from samba4
Andrew Tridgell [Mon, 16 Apr 2007 04:13:10 +0000 (14:13 +1000)] 
merged from samba4
(This used to be ctdb commit 541814e6ee3dd7f8f1b3fb615213ff5979b6e22f)

18 years agopull out common command line code for tests into tests/cmdline.c
Andrew Tridgell [Mon, 16 Apr 2007 04:12:50 +0000 (14:12 +1000)] 
pull out common command line code for tests into tests/cmdline.c
(This used to be ctdb commit de3db72c1fd0e56ac2b8d8fe962c725dc64f2051)

18 years agomerge from tridge
Ronnie sahlberg [Mon, 16 Apr 2007 02:50:48 +0000 (12:50 +1000)] 
merge from tridge

(This used to be ctdb commit b40bb042e5a29c61161421d7451368b11ad757e9)

18 years agomerge CTDB_SRVID_ALL patch from Samba4
Andrew Tridgell [Mon, 16 Apr 2007 00:31:39 +0000 (10:31 +1000)] 
merge CTDB_SRVID_ALL patch from Samba4
(This used to be ctdb commit 43cd05ab58e940a1ef0352aabe0b63075264a7a0)

18 years ago- fix includes to work in both samba4 and ctdb standalone
Andrew Tridgell [Mon, 16 Apr 2007 00:21:44 +0000 (10:21 +1000)] 
- fix includes to work in both samba4 and ctdb standalone
- when we do a store_unlock the lock record becomes unlocked, so we
  must destroy it (or we leak memory)

(This used to be ctdb commit d85955640e670dd580073da96b25fb8a10c08d18)

18 years agoadded --dblist option to ctdbd, to allow list of databases to be specified on the...
Andrew Tridgell [Sun, 15 Apr 2007 23:29:10 +0000 (09:29 +1000)] 
added --dblist option to ctdbd, to allow list of databases to be specified on the command line
(This used to be ctdb commit a19df59e9c2ea24d92a483f8a44514f492d49601)

18 years agomerge from ronnie
Andrew Tridgell [Sun, 15 Apr 2007 22:58:57 +0000 (08:58 +1000)] 
merge from ronnie
(This used to be ctdb commit af32b215f67d3bedb1bed542960f3f3813b3f60c)

18 years agoadd code to fetch1 test to tell the two child processes one at a time to fetch_lock...
Ronnie sahlberg [Sun, 15 Apr 2007 22:37:27 +0000 (08:37 +1000)] 
add code to fetch1 test to tell the two child processes one at a time to fetch_lock the same record

they both successfully fetch and lock the same record at this stage  but when the actual locking works properly  the second child will block.

this test allows us to verify the blocking once we have implemented it

(This used to be ctdb commit b1c0baa03a669757aaacb6e1a2794224f5ba2cd7)

18 years agoadd examples for volker on how to do fetchlock/storeunlock
Ronnie sahlberg [Sun, 15 Apr 2007 04:39:23 +0000 (14:39 +1000)] 
add examples for volker on how to do fetchlock/storeunlock

note that the actual locking/unl;ocking does not still work

(This used to be ctdb commit 45505520a69a2fbbb1e3a015b54d2133924f46a4)

18 years agoupdate to fetch1.sh test
Ronnie sahlberg [Sun, 15 Apr 2007 04:02:39 +0000 (14:02 +1000)] 
update to fetch1.sh test

there is still a bug in the ctdb code in that the children no longer receive messages from the parent for unknown reasons

(This used to be ctdb commit 468f68e4607900c5c38aea428a48dd6ea1647411)

18 years agomerge from tridge
Ronnie sahlberg [Sat, 14 Apr 2007 21:41:35 +0000 (07:41 +1000)] 
merge from tridge

(This used to be ctdb commit 7e111784a156cc6ed15645db4a911701673d7c2a)

18 years agomerge from ronnie
Andrew Tridgell [Sat, 14 Apr 2007 10:44:43 +0000 (20:44 +1000)] 
merge from ronnie
(This used to be ctdb commit 867468a7aadc11d0cb4d9f0eab55d3f34f11d6d3)

18 years agomerge from tridge
Ronnie sahlberg [Fri, 13 Apr 2007 11:10:20 +0000 (21:10 +1000)] 
merge from tridge

(This used to be ctdb commit 9c4e5569b82d9c7894e3ac1d5f0783c4d770daf4)

18 years agoprivate -> private_data for samba3
Andrew Tridgell [Fri, 13 Apr 2007 10:38:24 +0000 (20:38 +1000)] 
private -> private_data for samba3
(This used to be ctdb commit 080b6901173afb2ad618dd0621876ff478c7d6e5)

18 years agoadd missing code to store_unlock so that the data that a client writes is stored...
Ronnie sahlberg [Fri, 13 Apr 2007 10:37:41 +0000 (20:37 +1000)] 
add missing code to store_unlock so that the data that a client writes is stored in ltdb

this makes it possible to do fetch_lock and store_unlock across a domain socket to read/write data.

note that the actual locking is NOT implemented yet

(This used to be ctdb commit c7a397c56caf71283c081e5b97620085ed5108c6)

18 years agomerge store_unlock code from ronnie
Andrew Tridgell [Fri, 13 Apr 2007 05:49:33 +0000 (15:49 +1000)] 
merge store_unlock code from ronnie
(This used to be ctdb commit eb6f05528c14de5145323d0ff93baf6fb89518de)

18 years agoadd more elaborate test to fetch1 test
Ronnie sahlberg [Thu, 12 Apr 2007 23:44:56 +0000 (09:44 +1000)] 
add more elaborate test to fetch1 test

for now:
fetch a record
store a known entry for this record
fetch the record again  (and later verify we got the same record)
store it back again

this will not work right now since we dont yet store the record inside the daemon

(This used to be ctdb commit f502094499a3c25ab58aa3d192588b5e6dd2b8e4)

18 years agoadd store_unlock pdu's for the domain socket.
Ronnie sahlberg [Thu, 12 Apr 2007 23:41:15 +0000 (09:41 +1000)] 
add store_unlock pdu's for the domain socket.

note that the store_unlock does not actually do anything yet apart from passing the pdu from client to daemon   and daemon responds.

next is to make sure the daemon actually stores the data in a database

(This used to be ctdb commit 167d6993e78f6a1d0f6607ef66925a14993ae6a1)

18 years agomerge from tridge
Ronnie sahlberg [Thu, 12 Apr 2007 11:35:16 +0000 (21:35 +1000)] 
merge from tridge

(This used to be ctdb commit e7c318394b51936c7afef9451b8e32c42fac9829)

18 years agomerge from ronnie
Andrew Tridgell [Thu, 12 Apr 2007 11:32:16 +0000 (21:32 +1000)] 
merge from ronnie
(This used to be ctdb commit 8a6d3a2766d878f15892bf070536fd121424c9f7)

18 years agoadd the two missing file from the previous commit
Ronnie sahlberg [Thu, 12 Apr 2007 11:19:00 +0000 (21:19 +1000)] 
add the two missing file from the previous commit

(This used to be ctdb commit 3753b64e4e64446dc1f20ec92b45ba11bc0e0be5)

18 years agoadd a beginning of a new test
Ronnie sahlberg [Thu, 12 Apr 2007 11:17:10 +0000 (21:17 +1000)] 
add a beginning of a new test

right now this test only does one fetch lock   but this will be enhanced as more code is added to ctdb to handle fetch_lock and store_unlock

(This used to be ctdb commit 996f117d9181dee22aea979ce04333035f5522c7)

18 years agowhen sending back a fetch lock reply to a client
Ronnie sahlberg [Thu, 12 Apr 2007 11:14:41 +0000 (21:14 +1000)] 
when sending back a fetch lock reply to a client
we cant peek in state->c since this is uninitialized
and even if it were not it would be wrong

create a new structure to pass BOTH client and also the reqid to respond back to
the client with

(This used to be ctdb commit e1a0da3dfbb4a927e8d98723b5e51a201c2a3428)

18 years agomerge from tridges tree
Ronnie sahlberg [Thu, 12 Apr 2007 07:13:48 +0000 (17:13 +1000)] 
merge from tridges tree

(This used to be ctdb commit 63669f4b965fd03503bdbfe389243750c376a289)

18 years agomerge from ronnie
Andrew Tridgell [Thu, 12 Apr 2007 06:51:33 +0000 (16:51 +1000)] 
merge from ronnie
(This used to be ctdb commit 0e351d1655e380fbb35e45d15f4ba3ccc15097e4)

18 years agodont hardcode gdb in the test script. ooops
Ronnie sahlberg [Thu, 12 Apr 2007 06:49:37 +0000 (16:49 +1000)] 
dont hardcode gdb in the test script.     ooops

(This used to be ctdb commit e193d69cd8cdd293379ab88d25e6984b584afa22)

18 years agoinitial support for two new pdus for the domain socket to do fetch_lock
Ronnie sahlberg [Thu, 12 Apr 2007 05:46:50 +0000 (15:46 +1000)] 
initial support for two new pdus for the domain socket to do fetch_lock

no locking is yet done and the store_unlock call is still missing

the ./tests/fetch.sh --daemon  test fails with parent process dying which needs to be investigated.

(This used to be ctdb commit 7d7141c968950a8856f1be79871932b688bfb07f)

18 years agomerge from volker
Ronnie sahlberg [Thu, 12 Apr 2007 00:52:19 +0000 (10:52 +1000)] 
merge from volker

(This used to be ctdb commit c59e92829364aefdd4f8f4972b47135faca69006)

18 years agomerge from vl
Andrew Tridgell [Thu, 12 Apr 2007 00:51:55 +0000 (10:51 +1000)] 
merge from vl
(This used to be ctdb commit 8b5233fbe773893d1bc6b377f8956fe0b3e503ab)

18 years agomerge from ronnie
Andrew Tridgell [Thu, 12 Apr 2007 00:44:18 +0000 (10:44 +1000)] 
merge from ronnie
(This used to be ctdb commit b4c9dd2f2c014039afca3a225375a4aefee14113)

18 years agoadd an example on how to read a message from the domain socket
Ronnie sahlberg [Wed, 11 Apr 2007 23:09:27 +0000 (09:09 +1000)] 
add an example on how to read a message from the domain socket

(This used to be ctdb commit 9723828b1562eb6a386eb26e63db3b6617ebb454)

18 years agodo an infinite loop calling event_loop_once() in the ctdbd parent process instead...
Ronnie sahlberg [Wed, 11 Apr 2007 22:44:15 +0000 (08:44 +1000)] 
do an infinite loop calling event_loop_once() in the ctdbd parent process instead of event_loop_wait()  since the latter will return and thus take down the daemon

(This used to be ctdb commit 26ffd166c176deb7e2437f3ee87887f8b57435e7)

18 years agoadd a test message to the messaging test so we can see that the message data is also...
Ronnie sahlberg [Wed, 11 Apr 2007 22:28:54 +0000 (08:28 +1000)] 
add a test message to the messaging test so we can see that the message data is also passed from originator to receiver

(This used to be ctdb commit f9c2ed3cff8eb481bfa80d944d86233e2a7d5d00)

18 years agomerge from ridge and vl
Ronnie sahlberg [Wed, 11 Apr 2007 21:49:28 +0000 (07:49 +1000)] 
merge from ridge and vl

(This used to be ctdb commit 8d407c5858a20c9757024f19033b5ef174ec3681)

18 years agoRename "private" to "private_data"
Volker Lendecke [Wed, 11 Apr 2007 18:12:15 +0000 (20:12 +0200)] 
Rename "private" to "private_data"
(This used to be ctdb commit 78cf4443ac0c66fb750ef6919bcdec189ac219c9)

18 years agoMerge tridge's tree
Volker Lendecke [Wed, 11 Apr 2007 14:52:06 +0000 (16:52 +0200)] 
Merge tridge's tree

(This used to be ctdb commit 63a59a700a1fb4c23cd76d99c5b4c9660c7ca475)

18 years agoAdd a test to read back the message
Volker Lendecke [Wed, 11 Apr 2007 14:51:25 +0000 (16:51 +0200)] 
Add a test to read back the message

Volker

(This used to be ctdb commit b7f134fe6e160d7ec70c466f8f3e7fb3dabd0774)

18 years agouse event_loop_wait instead of while(1)
Andrew Tridgell [Wed, 11 Apr 2007 12:21:43 +0000 (22:21 +1000)] 
use event_loop_wait instead of while(1)
(This used to be ctdb commit e49a6436483bffcf867fbb746ef43a5356055857)

18 years agouse lib/replace for signal.h
Andrew Tridgell [Wed, 11 Apr 2007 12:19:46 +0000 (22:19 +1000)] 
use lib/replace for signal.h
(This used to be ctdb commit 4c660b9706ef09527b8e1a2837d844d30672c541)

18 years agomerge from volker
Andrew Tridgell [Wed, 11 Apr 2007 12:17:24 +0000 (22:17 +1000)] 
merge from volker
(This used to be ctdb commit 68bc5b4d0d2049ebcee19338f744efd5b129725a)

18 years agomerge from ronnie
Andrew Tridgell [Wed, 11 Apr 2007 12:11:07 +0000 (22:11 +1000)] 
merge from ronnie
(This used to be ctdb commit 6cd4b1ec40b51f491d25173a7dde0864f525e7ef)

18 years agomerge
Volker Lendecke [Wed, 11 Apr 2007 11:57:58 +0000 (13:57 +0200)] 
merge
(This used to be ctdb commit 89c24a2ee211126d24e770abb8f91c5575126246)

18 years agoHandle a client that exited correctly: We need to ignore SIGPIPE and when the
Volker Lendecke [Wed, 11 Apr 2007 11:17:36 +0000 (13:17 +0200)] 
Handle a client that exited correctly: We need to ignore SIGPIPE and when the
read returns 0 bytes this means the client has exited. Close the connection
then.

(This used to be ctdb commit bd10f4e62146493848258df8a3dc3b9222337a12)

18 years agoFix uninitialized variable warnings
Volker Lendecke [Wed, 11 Apr 2007 10:49:10 +0000 (12:49 +0200)] 
Fix uninitialized variable warnings

(This used to be ctdb commit b84f97adfd25b2fbfab1c7964b68931643e8029c)

18 years agoadd an example on how to send a message to the daemon
Ronnie sahlberg [Wed, 11 Apr 2007 10:32:24 +0000 (20:32 +1000)] 
add an example on how to send a message to the daemon
(send a message to ourself)

this unfortunately terminates the ctdb daemon when running   but im too tired right now to debug it.
checkin so that nothing gets lost overnight.

(This used to be ctdb commit 9d8821bfd1456591fb5c31f0c6c3fd63e99dc4fb)

18 years agoadd call/reply parsing of the cluster connect-wait call to the test daemon.
Ronnie sahlberg [Wed, 11 Apr 2007 09:27:19 +0000 (19:27 +1000)] 
add call/reply parsing of the cluster connect-wait call to the test daemon.

(This used to be ctdb commit c54c87feb89b8d97655c1fcd748a295119a1171f)

18 years agoadd a vnn field to the ctdb_reply_connect_wait pdu so that we can tell
Ronnie sahlberg [Wed, 11 Apr 2007 09:04:09 +0000 (19:04 +1000)] 
add a vnn field to the ctdb_reply_connect_wait pdu so that we can tell
non-ctdb-linked clients what the vnn of the local cluster daemon is

(This used to be ctdb commit 57fd1aa54b234545e1e465b5ace2ce93fcfbc22a)

18 years agocreate a standalone ctdb daemon and a script ./direct/ctdbd.sh to start two such...
Ronnie sahlberg [Wed, 11 Apr 2007 08:54:22 +0000 (18:54 +1000)] 
create a standalone ctdb daemon and a script ./direct/ctdbd.sh to start two such daemons in a 2 node cluster.

create a small test application that connects to the ctdb daemon at /tmp/ctdb.socket.127.0.0.1 and do some commands to the daemon.
currently this test tool only opens the socket and registers its pid with the daemon
(the daemon needs to know the pid so that it can forward messages to the correct client)

the test will be extended with additional ctdb commands

(This used to be ctdb commit 801f6127cdd50c5b2d0e64dd8db08500af9dadc9)

18 years agomerge from tridge
Ronnie sahlberg [Wed, 11 Apr 2007 05:40:03 +0000 (15:40 +1000)] 
merge from tridge

(This used to be ctdb commit 257a167d7e8b532c03a122626dbc2db767dbfdf0)

18 years agoadded --num-clients option to ctdb_messaging test
Andrew Tridgell [Wed, 11 Apr 2007 05:23:50 +0000 (15:23 +1000)] 
added --num-clients option to ctdb_messaging test
(This used to be ctdb commit 2f4e7e34071c8950f6c4d64469c5eb15d0888113)

18 years agouse the new connect_wait code in the ctdb_messaging test
Andrew Tridgell [Wed, 11 Apr 2007 05:09:22 +0000 (15:09 +1000)] 
use the new connect_wait code in the ctdb_messaging test
(This used to be ctdb commit 36980878141c5e506dd7ee021fba6ca7d0ff5ad3)

18 years agoadd proper support for ctdb_connect_wait in daemon mode
Andrew Tridgell [Wed, 11 Apr 2007 04:54:47 +0000 (14:54 +1000)] 
add proper support for ctdb_connect_wait in daemon mode
(This used to be ctdb commit 8d110df5939b3e6a6341909956453887f4eb6b0d)

18 years agofixed sending messages to ourselves in non-daemon mode
Andrew Tridgell [Wed, 11 Apr 2007 04:26:14 +0000 (14:26 +1000)] 
fixed sending messages to ourselves in non-daemon mode
(This used to be ctdb commit 325afd2de2f5a96fb4f8ec624e04f253c712c97d)

18 years agomerge from ronnie, plus complete the client side of inter-node messaging
Andrew Tridgell [Wed, 11 Apr 2007 04:05:01 +0000 (14:05 +1000)] 
merge from ronnie, plus complete the client side of inter-node messaging
(This used to be ctdb commit e605417436855d22343462acae4cbb79a374977e)

18 years agoadd a test that sends messages between clients connected to the same ctdb
Ronnie sahlberg [Wed, 11 Apr 2007 03:43:15 +0000 (13:43 +1000)] 
add a test that sends messages between clients connected to the same ctdb

add code to actually pass the messages between clients and ctdb

(This used to be ctdb commit 6d5b55d7b9c611fb5e98765906757a7d82e4bf6b)

18 years agopartially completed work towards full messaging system which will work in both daemon...
Andrew Tridgell [Wed, 11 Apr 2007 01:58:28 +0000 (11:58 +1000)] 
partially completed work towards full messaging system which will work in both daemon and standalone mode. Does not compile\! committing so ronnie can continue while I'm out
(This used to be ctdb commit 1b5e65a700e2bd0a5c913d7866024b25600a14c9)

18 years agomerge from ronnie
Andrew Tridgell [Wed, 11 Apr 2007 01:11:44 +0000 (11:11 +1000)] 
merge from ronnie
(This used to be ctdb commit dd6cec4ed8cda0112120af3967dd06b9e7b9341b)