summaryrefslogtreecommitdiffstats
path: root/ctdb
Commit message (Collapse)AuthorAgeFilesLines
...
* | do not use a ctdb_record_handle for client fetch_lock/store_unlock any moreRonnie sahlberg2007-04-174-63/+37
| | | | | | | | | | | | | | | | | | | | 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)
* | remaning code to finish lock_fetch/store_unlock clientside helpersRonnie sahlberg2007-04-174-28/+83
|\ \ | | | | | | | | | (This used to be ctdb commit edf1e1fea8500461a08cd2795251a5cc0bd10229)
| * \ merge from ronnieAndrew Tridgell2007-04-172-10/+10
| |\ \ | | | | | | | | | | | | (This used to be ctdb commit fcf3669c27691ddb383d1c585234622efa498d90)
| * | | partial merge from volker (some overlaps removed)Andrew Tridgell2007-04-172-24/+54
| | | | | | | | | | | | | | | | (This used to be ctdb commit c4747460a8e0017acfd2a97a632ecd9395562d4f)
| * | | better error handling in ctdb_ltdb_lock_fetch_requeue()Andrew Tridgell2007-04-171-2/+19
| | | | | | | | | | | | | | | | (This used to be ctdb commit 1952be19f625dbe257050acebf468e7e6eb0da8c)
* | | | initial change to remove store_unlock pdu and use tdb chainlock in the clientRonnie sahlberg2007-04-178-271/+49
| |/ / |/| | | | | | | | (This used to be ctdb commit 87dd265d2c61125ca2fa922cfcf9371a234fff0c)
* | | change some error printouts to make it easier to determine whether the error ↵Ronnie sahlberg2007-04-172-10/+10
|/ / | | | | | | | | | | occured in the client or in the daemon (This used to be ctdb commit a7e42c2c56e38b4b58ede0ad45767695d704dac4)
* | add an explanation of ctdb_ltdb_lock_fetch_requeue()Andrew Tridgell2007-04-171-0/+15
| | | | | | | | (This used to be ctdb commit 7c749315130a2bc87dcc07460d10dcb089ae4202)
* | add an explanation of how to use ctdb_lockwait()Andrew Tridgell2007-04-171-1/+10
| | | | | | | | (This used to be ctdb commit e0c9844ea6270ff506b0b5906aa6ccfcc3bcce7a)
* | fixed crash bug - thanks volkerAndrew Tridgell2007-04-171-1/+2
| | | | | | | | (This used to be ctdb commit e293f6fadf673d8bc7203198d709bcb28c26b482)
* | darn, forgot thisAndrew Tridgell2007-04-172-1/+108
| | | | | | | | (This used to be ctdb commit 0feb5da60c0331f6c391622910ca1f436263ce46)
* | wait on the right fd ....Andrew Tridgell2007-04-171-1/+2
| | | | | | | | (This used to be ctdb commit 27b67ee6576b17f8b3aae024ae3bd0bb1c42f0f2)
* | added a ctdb_ltdb_lock_fetch_requeue() functionAndrew Tridgell2007-04-164-2/+56
| | | | | | | | | | | | | | 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)
| * merged tridge's branch Peter Somogyi2007-04-1659-856/+4997
| |\ | |/ |/| | | (This used to be ctdb commit 15e18293eaa5ddcd325395213014b5a4498ca309)
* | added a tdb_chainlock_nonblock() call to tdbAndrew Tridgell2007-04-162-4/+30
| | | | | | | | (This used to be ctdb commit 6587bdca71d97709c9271a73aea0be5a2a35f399)
* | merge local copy of tdb from samba4 tdbAndrew Tridgell2007-04-1615-361/+763
| | | | | | | | (This used to be ctdb commit d4619ce98ce44acaebeb6ae9c516a7917bf4e27f)
* | fixed a fd bug (thanks volker)Andrew Tridgell2007-04-161-0/+1
| | | | | | | | (This used to be ctdb commit 512a96de1b31e856785749ffc0bed60b1c589f9e)
* | this is a demonstration of an idea for handling locks in ctdb.Andrew Tridgell2007-04-165-2/+258
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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)
* | merged from samba4Andrew Tridgell2007-04-161-0/+29
| | | | | | | | (This used to be ctdb commit 541814e6ee3dd7f8f1b3fb615213ff5979b6e22f)
* | pull out common command line code for tests into tests/cmdline.cAndrew Tridgell2007-04-168-243/+134
| | | | | | | | (This used to be ctdb commit de3db72c1fd0e56ac2b8d8fe962c725dc64f2051)
* | merge CTDB_SRVID_ALL patch from Samba4Andrew Tridgell2007-04-163-2/+8
| | | | | | | | (This used to be ctdb commit 43cd05ab58e940a1ef0352aabe0b63075264a7a0)
* | - fix includes to work in both samba4 and ctdb standaloneAndrew Tridgell2007-04-165-4/+9
| | | | | | | | | | | | | | - 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)
* | added --dblist option to ctdbd, to allow list of databases to be specified ↵Andrew Tridgell2007-04-161-6/+15
| | | | | | | | | | | | on the command line (This used to be ctdb commit a19df59e9c2ea24d92a483f8a44514f492d49601)
* | add code to fetch1 test to tell the two child processes one at a time to ↵Ronnie sahlberg2007-04-161-12/+32
| | | | | | | | | | | | | | | | | | | | 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)
* | add examples for volker on how to do fetchlock/storeunlockRonnie sahlberg2007-04-152-4/+160
| | | | | | | | | | | | note that the actual locking/unl;ocking does not still work (This used to be ctdb commit 45505520a69a2fbbb1e3a015b54d2133924f46a4)
* | update to fetch1.sh testRonnie sahlberg2007-04-151-22/+109
| | | | | | | | | | | | 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)
* | merge from tridgeRonnie sahlberg2007-04-1316-60/+60
|\ \ | | | | | | | | | (This used to be ctdb commit 9c4e5569b82d9c7894e3ac1d5f0783c4d770daf4)
| * | private -> private_data for samba3Andrew Tridgell2007-04-1316-60/+60
| | | | | | | | | | | | (This used to be ctdb commit 080b6901173afb2ad618dd0621876ff478c7d6e5)
* | | add missing code to store_unlock so that the data that a client writes is ↵Ronnie sahlberg2007-04-133-16/+47
|/ / | | | | | | | | | | | | | | | | | | | | 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)
* | add more elaborate test to fetch1 testRonnie sahlberg2007-04-131-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | 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)
* | add store_unlock pdu's for the domain socket.Ronnie sahlberg2007-04-135-2/+186
| | | | | | | | | | | | | | | | 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)
* | add the two missing file from the previous commitRonnie sahlberg2007-04-122-0/+159
| | | | | | | | (This used to be ctdb commit 3753b64e4e64446dc1f20ec92b45ba11bc0e0be5)
* | add a beginning of a new testRonnie sahlberg2007-04-121-1/+5
| | | | | | | | | | | | 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)
* | when sending back a fetch lock reply to a client Ronnie sahlberg2007-04-121-3/+12
| | | | | | | | | | | | | | | | | | | | 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)
* | dont hardcode gdb in the test script. ooopsRonnie sahlberg2007-04-121-1/+1
| | | | | | | | (This used to be ctdb commit e193d69cd8cdd293379ab88d25e6984b584afa22)
* | initial support for two new pdus for the domain socket to do fetch_lockRonnie sahlberg2007-04-129-27/+317
| | | | | | | | | | | | | | | | | | 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)
* | merge from vlAndrew Tridgell2007-04-126-36/+45
|\ \ | | | | | | | | | (This used to be ctdb commit 8b5233fbe773893d1bc6b377f8956fe0b3e503ab)
| * | Rename "private" to "private_data"Volker Lendecke2007-04-115-20/+24
| | | | | | | | | | | | (This used to be ctdb commit 78cf4443ac0c66fb750ef6919bcdec189ac219c9)
| * | Merge tridge's treeVolker Lendecke2007-04-111-5/+3
| |\ \ | | | | | | | | | | | | (This used to be ctdb commit 63a59a700a1fb4c23cd76d99c5b4c9660c7ca475)
| * | | Add a test to read back the messageVolker Lendecke2007-04-111-0/+37
| | | | | | | | | | | | | | | | | | | | | | | | Volker (This used to be ctdb commit b7f134fe6e160d7ec70c466f8f3e7fb3dabd0774)
* | | | add an example on how to read a message from the domain socketRonnie sahlberg2007-04-121-3/+35
| | | | | | | | | | | | | | | | (This used to be ctdb commit 9723828b1562eb6a386eb26e63db3b6617ebb454)
* | | | do an infinite loop calling event_loop_once() in the ctdbd parent process ↵Ronnie sahlberg2007-04-121-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | instead of event_loop_wait() since the latter will return and thus take down the daemon (This used to be ctdb commit 26ffd166c176deb7e2437f3ee87887f8b57435e7)
* | | | add a test message to the messaging test so we can see that the message data ↵Ronnie sahlberg2007-04-121-4/+6
| |/ / |/| | | | | | | | | | | | | | is also passed from originator to receiver (This used to be ctdb commit f9c2ed3cff8eb481bfa80d944d86233e2a7d5d00)
* | | use event_loop_wait instead of while(1)Andrew Tridgell2007-04-111-4/+2
| | | | | | | | | | | | (This used to be ctdb commit e49a6436483bffcf867fbb746ef43a5356055857)
* | | use lib/replace for signal.hAndrew Tridgell2007-04-111-1/+1
|/ / | | | | | | (This used to be ctdb commit 4c660b9706ef09527b8e1a2837d844d30672c541)
* | Handle a client that exited correctly: We need to ignore SIGPIPE and when theVolker Lendecke2007-04-112-0/+20
| | | | | | | | | | | | | | read returns 0 bytes this means the client has exited. Close the connection then. (This used to be ctdb commit bd10f4e62146493848258df8a3dc3b9222337a12)
* | Fix uninitialized variable warningsVolker Lendecke2007-04-111-2/+6
| | | | | | | | (This used to be ctdb commit b84f97adfd25b2fbfab1c7964b68931643e8029c)
* | add an example on how to send a message to the daemonRonnie sahlberg2007-04-111-1/+38
| | | | | | | | | | | | | | | | | | (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)
* | add call/reply parsing of the cluster connect-wait call to the test daemon.Ronnie sahlberg2007-04-111-4/+60
| | | | | | | | (This used to be ctdb commit c54c87feb89b8d97655c1fcd748a295119a1171f)
* | add a vnn field to the ctdb_reply_connect_wait pdu so that we can tellRonnie sahlberg2007-04-112-0/+2
| | | | | | | | | | | | non-ctdb-linked clients what the vnn of the local cluster daemon is (This used to be ctdb commit 57fd1aa54b234545e1e465b5ace2ce93fcfbc22a)