1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-28 07:21:54 +03:00
Commit Graph

6 Commits

Author SHA1 Message Date
Andrew Tridgell
bf3b740a1b ctdb is GPL not LGPL
(This used to be ctdb commit 8624378010d1c2a1438e1e701339dfba7276f960)
2007-05-31 13:50:53 +10:00
Andrew Tridgell
1e2d91c761 moved cmdline.c to common code
(This used to be ctdb commit 32b31a6b91a19fc0c5225cb88c35cc1d14b4a6df)
2007-04-17 22:16:50 +10:00
Andrew Tridgell
4c787fdff5 darn, forgot this
(This used to be ctdb commit 0feb5da60c0331f6c391622910ca1f436263ce46)
2007-04-17 07:41:27 +10:00
Andrew Tridgell
fca41760e3 wait on the right fd ....
(This used to be ctdb commit 27b67ee6576b17f8b3aae024ae3bd0bb1c42f0f2)
2007-04-17 00:11:04 +10:00
Andrew Tridgell
b3ed006ef4 fixed a fd bug (thanks volker)
(This used to be ctdb commit 512a96de1b31e856785749ffc0bed60b1c589f9e)
2007-04-16 22:49:37 +10:00
Andrew Tridgell
07ade5e488 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)
2007-04-16 16:01:37 +10:00