Ronnie Sahlberg
14724b504b
cleanup the control "write record"
...
(This used to be ctdb commit 4dd5c26a21a5dc2b2f76eb23cfeb4df82ba4e956)
2007-05-03 16:18:03 +10:00
Ronnie Sahlberg
e7cd7e4cde
merge from tridge
...
(This used to be ctdb commit abf4c9d0cccd937a7036bd03b1b4c6e635c8eb58)
2007-05-03 14:42:53 +10:00
Andrew Tridgell
486c6b4fce
merged from ronnie
...
(This used to be ctdb commit 57a80110ddfd202f8de37297db76dc43a064e476)
2007-05-03 13:53:54 +10:00
Andrew Tridgell
de0f848556
don't zero beyond packet header unnecessarily
...
(This used to be ctdb commit 4cf88ca2ce81db8fe10b0dfedb81d99a2bd93328)
2007-05-03 13:44:27 +10:00
Ronnie Sahlberg
d88154b24a
cleanup getnodemap
...
(This used to be ctdb commit 3867ccf71a167fb82dbc5a3f03f968a325a0c70b)
2007-05-03 13:30:38 +10:00
Ronnie Sahlberg
633ae7f346
fixup getdbmap control so it looks a bit nicer
...
(This used to be ctdb commit 78a4d61cb78da20af5210488e685c91bc3023e90)
2007-05-03 13:07:34 +10:00
Andrew Tridgell
472b96d6d3
first stage of efficient non-blocking ctdb traverse
...
(This used to be ctdb commit 4c23e6f26bde421bb56b55de9d6cd3e319b2be40)
2007-05-03 12:16:03 +10:00
Andrew Tridgell
475cfa245c
merged cleanup from ronnie
...
(This used to be ctdb commit 971e7f82f3e1e9bfc8d521080c86431fbb59277d)
2007-05-03 11:13:01 +10:00
Ronnie Sahlberg
27880056db
break set/get vnn map out from ctdb_control and put it in ctdb_recover.c
...
for the time being
remove all the [de]marshalling and just pass a structure around instead
(This used to be ctdb commit b1169555ab7015976c0135ff51121cc238f5887c)
2007-05-03 11:06:24 +10:00
Andrew Tridgell
b0b966de66
merge from ronnie
...
(This used to be ctdb commit bac8eed2c247a7970836c0e6c2b9e2664922f410)
2007-05-03 07:48:08 +10:00
Ronnie Sahlberg
3e546cf134
merge from tridge
...
(This used to be ctdb commit ae72aac605d0c68134d65c213d76496e6293ebc4)
2007-05-03 07:21:29 +10:00
Andrew Tridgell
622dbb6337
merge from ronnie
...
(This used to be ctdb commit daba707370b28e200d9e55eb81fc819b62f8fbdd)
2007-05-03 07:19:29 +10:00
Ronnie Sahlberg
3dad8e6413
merge from tridge
...
(This used to be ctdb commit 2321a2a31e43208f16d6af15ee55a489670de005)
2007-05-03 05:52:45 +10:00
Andrew Tridgell
f51a988b74
fixed a memory leak in the ctdb_control code
...
(This used to be ctdb commit 70aa77a66bb5f16c93ecb122b92a6e63f6343ab1)
2007-05-03 05:51:46 +10:00
Andrew Tridgell
6c114bb1bd
enabled built in popt if system doesn't have it
...
(This used to be ctdb commit 30c8d69267a78e1d3dea0fcc936ee2939bb7a373)
2007-05-03 05:21:14 +10:00
Ronnie Sahlberg
768eb0f763
merge from tridge
...
(This used to be ctdb commit 17b73a811009588f836c3f9fd1b775d9d504d30c)
2007-05-02 22:00:48 +10:00
Ronnie Sahlberg
fe24692d46
do a real recovery by killing a node and then calling the recover
...
control
(This used to be ctdb commit f8d97f8b56f0af83a514ec0364eb915e2d5ea2d7)
2007-05-02 21:31:20 +10:00
Ronnie Sahlberg
97504b62e2
recover.sh test script that build a few database and populates them with
...
a record then performs a recovery which merges all records onto node 0
(This used to be ctdb commit 54a072deb40d8d4a4a9e35bfde0eec3c867211d0)
2007-05-02 21:14:37 +10:00
Ronnie Sahlberg
206fb1fd3b
add a recover test change alignment for the pull/push db structures
...
(This used to be ctdb commit 0eb45623ca103e69765ed577ae02e7f8ca777e37)
2007-05-02 21:00:02 +10:00
Andrew Tridgell
317ad52758
added a builtin fetch function to support samba3 unlocked fetch
...
(This used to be ctdb commit 8c57a8355a94a7d714b9bec98533bc40a2bc4684)
2007-05-02 15:11:11 +10:00
Andrew Tridgell
2767ebb8df
nicer command parsing in ctdb_control
...
(This used to be ctdb commit 440077ffabb4ce831004b36ac26bd2f8f9b41499)
2007-05-02 13:34:55 +10:00
Ronnie Sahlberg
a1cac30684
discard REQ/REPLY DMASTER when generation id is wrong or when in
...
recovery mode
(This used to be ctdb commit bfd6d430f22e38cff1d64510dc447cfbe1dab35f)
2007-05-02 13:31:42 +10:00
Andrew Tridgell
353762fd18
nicer string handling in usage
...
(This used to be ctdb commit 8c568ada9b46132ebfa452def4f8ba3f11240532)
2007-05-02 13:29:03 +10:00
Andrew Tridgell
0415881893
merged from ronnie
...
(This used to be ctdb commit 77255f93d432829387dc328b0ae726cc9cba8d68)
2007-05-02 13:25:45 +10:00
Ronnie Sahlberg
c06c1e1f9f
remove sleep from the fetch test
...
add a test script to start 4 daemons to test recovery
(This used to be ctdb commit 09eab12b00934afa5159fc500faf6b07effb2804)
2007-05-02 13:14:12 +10:00
Ronnie Sahlberg
d20990c2b6
add a control to create a database
...
(This used to be ctdb commit 74e489c6737cc79537c7812ea82daafb1b363ec2)
2007-05-02 12:43:35 +10:00
Ronnie Sahlberg
1f84807005
remove test code in the fetch test to keep the daemons running forever
...
(so one has lots of tiume to play with ctdb_control)
(This used to be ctdb commit 8fbaf82a7b3f0e62c887e91731ad8c659122c785)
2007-05-02 11:09:10 +10:00
Ronnie Sahlberg
9d20a09631
change the getnodemap control to a more consistent output for whether a
...
node is connected or not
(This used to be ctdb commit 65c5fe53937a17e1fa6de5739cbd01b982dc49bb)
2007-05-02 11:06:58 +10:00
Ronnie Sahlberg
599fa31266
update some calls to ctdb_control() that were still using the old
...
signature (flags field)
update some calls to ctdb_get_config() to use the new name
ctdb_ctrl_get_config()
change #include "talloc/talloc.h" to #include "lib/talloc/talloc.h" in
lib/events/events.h
(This used to be ctdb commit d2cdd87037b9f0c387228d7d4743da4869929c93)
2007-05-02 11:02:04 +10:00
Ronnie Sahlberg
3a891c6676
merge with tridges tree to resolve all conflicts
...
(This used to be ctdb commit 0f7c6c580ef0de60af68fd22bce36c0c0b2515b0)
2007-05-02 10:53:29 +10:00
Ronnie Sahlberg
92f5daf252
specify which node to perform recovery to when using the recovery
...
control
(This used to be ctdb commit c67f8a1783ce6f5af9940d2e22847ddcd939763d)
2007-05-02 10:37:43 +10:00
Ronnie Sahlberg
88e3ca3b2e
fix a bug in pushdb control.
...
we should only write the pushed record if RSN of the new one if higher
than the rsn of the existing one not the other way around
(This used to be ctdb commit f535008c3755cf84acff7bc73ea05c0901e940ef)
2007-05-02 10:25:14 +10:00
Ronnie Sahlberg
51630f9b12
add an initial recovery control to perform samba3 style recovery
...
this is not optimized at all and copies/merges all records between
databases instead of only those records for which a certain node is
lmaster. (step 7 should later be enhanced to a, delete the database,
push only those records for which the node is lmaster)
(This used to be ctdb commit 509d2c71169e96a8610f9db91293dc7a73c2cc10)
2007-05-02 10:20:34 +10:00
Andrew Tridgell
e93b52a323
new files for updated events system
...
(This used to be ctdb commit 15d8308e5a0ce04351d70ac3dd25c7698931ebba)
2007-05-02 07:37:58 +10:00
Andrew Tridgell
169f129404
merge latest versions of lib/replace, lib/talloc, lib/tdb and lib/events into ctdb bzr tree
...
(This used to be ctdb commit eaea8a9fa8d2f5e08f3af619fa1008a663f39053)
2007-05-02 07:32:04 +10:00
Andrew Tridgell
3a05ad1402
fixed a lib/events bug found by volker
...
(This used to be ctdb commit 46cd984500cd77d295f059132b4892dbfbc2bcd3)
2007-05-02 06:50:12 +10:00
Andrew Tridgell
2dc24c7d56
added a hopcount in ctdb_call
...
(This used to be ctdb commit 36d838801a2a2008c50322cdbfff65a308b1cd1a)
2007-05-01 13:25:02 +10:00
Andrew Tridgell
5b8c4bba5a
auto-determine listen address by attempting to bind to each address in the cluster in turn
...
(This used to be ctdb commit 2fab9f96df2e5b5c51c860fd65caf0e926a63e34)
2007-05-01 06:34:55 +10:00
Andrew Tridgell
bbf358cfcf
added attach command in ctdb_control
...
(This used to be ctdb commit 172ee33306be2ef5ce17a5b9d7fbcc1f265a1b0b)
2007-04-30 15:54:06 +02:00
Andrew Tridgell
9366120d92
changed the way set_call and attach are done so that you can safely
...
attach to databases after the protocol has started. The daemon
broadcasts information on new databases to the other daemons.
This also eliminates the need for the client to know about the hash
between db name and db_id.
(This used to be ctdb commit 3bad91a9d987d4c09fe3322eac23c2733660ad08)
2007-04-30 15:31:40 +02:00
Andrew Tridgell
4832d8f834
don't use stderr here - rely on logging
...
(This used to be ctdb commit a2a3b254b22dbaafc8c4934d99cc67d6ae4adbd1)
2007-04-30 11:10:21 +02:00
Andrew Tridgell
f455d3f44b
saner logfile code
...
testing of ctdbd
(This used to be ctdb commit 05789da5818f8b20f04779b0df5125914d9047f6)
2007-04-29 22:42:23 +02:00
Ronnie Sahlberg
eacfcaf437
add push/pull of tdb and a control to copy a tdb from one node to
...
another node
(This used to be ctdb commit c313daff4c1362cd08a9f682ce04cab312678038)
2007-04-30 00:58:27 +10:00
Andrew Tridgell
e21f69107f
yay! finally fixed the bug that volker, ronnie and I have been chasing
...
for 2 days.
The main bug was in smbd, but there was a secondary (and more subtle)
bug in ctdb that the bug in smbd exposed. When we get send a dmaster
reply, we have to correctly update the dmaster in the recipient even
if the original requst has timed out, otherwise ctdbd can get into a
loop fighting over who will handle a key.
This patch also cleans up the packet allocation, and makes ctdbd
become a real daemon.
(This used to be ctdb commit 59405e59ef522b97d8e20e4b14310a217141ac7c)
2007-04-29 16:19:40 +02:00
Ronnie Sahlberg
f67a79ad8e
merge from tridge
...
(This used to be ctdb commit a84e9b47a87fc7d4756b4a179aa2ea0bc7c54c78)
2007-04-29 23:49:27 +10:00
Ronnie Sahlberg
77ce5750b2
add a new "recovery mode" field to ctdb.
...
while recovery is in progress the daemon will discard all CTDB_REQ_CALL
and rely on clients retransmitting them
add new controls to get/set the recovery mode
(This used to be ctdb commit 41458a61577885ac49150f830e92e93e634c5411)
2007-04-29 22:51:56 +10:00
Ronnie Sahlberg
1af701291f
implement a control to pull a database from a remote node
...
it does not yet work since ctdb_control can right now only be called
from client context and the pull is implemented as the target ctdb node
itself using a get_keys to pull the keys from the source node thus
ctdb daemon needs to ctdb_control to a remote node
(This used to be ctdb commit a55c7c64b4ff87f54b90649c9f469b1ff36dc9ea)
2007-04-29 22:14:51 +10:00
Ronnie Sahlberg
376a3ea852
control to delete all records in a database
...
(This used to be ctdb commit 6664e00fc02e1c60cc1a35ecd15f4893a34f23d1)
2007-04-29 18:48:46 +10:00
Ronnie Sahlberg
c0b0b4a0f5
add a new control to set all records in a database to a new dmaster
...
(This used to be ctdb commit fd0d2385206b0329b74d908f3bdf89d3f32095d1)
2007-04-29 18:34:11 +10:00
Ronnie Sahlberg
097037a055
add a control to read an entire tdb from a node including
...
key/lmaster/header and data
(This used to be ctdb commit ac00d6271ba6356c1edf804df44d0d2600791610)
2007-04-29 05:47:13 +10:00