summaryrefslogtreecommitdiff
path: root/source3/include/messages.h
AgeCommit message (Collapse)AuthorFilesLines
2013-10-17s3:include: fix messaging_send_buf() protype in messages.hStefan Metzmacher1-1/+1
The function already used 'uint8_t' instead of 'uint8'. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-02-19s3:lib: s/struct event_context/struct tevent_contextStefan Metzmacher1-2/+2
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
2012-04-17s3: Add messaging_tdb_event()Volker Lendecke1-0/+3
This is a void* that represents a signal handler attached to some custom tevent_context. This is necessary to make the tdb based messaging infrastructure trigger its business when we are sitting in tevent_loop_once for an event context that is not the main one in the messaging context.
2012-01-17s3:lib/messages: remove unused messaging_event_context()Stefan Metzmacher1-1/+0
metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Tue Jan 17 09:45:30 CET 2012 on sn-devel-104
2011-12-12s3: Remove a bunch of calls to procid_self()Volker Lendecke1-3/+1
All callers to messaging_[re]init only used procid_self()
2011-10-12s3: factor out messaging_send_to_children()Gregor Beck1-0/+1
Signed-off-by: Michael Adam <obnox@samba.org>
2011-09-13s3: Fix some nonempty blank linesVolker Lendecke1-3/+3
2011-08-11s3-messaging: Change classification of MSG_SMB_CONF_UPDATED.Simo Sorce1-1/+0
smbd is not the only daemon interested in smb.conf changes. Move this message to the GENERAL class so that all interested partied (nmbd, winbindd, spoolssd, etc..) can receive this notification. Signed-off-by: Andreas Schneider <asn@samba.org>
2011-08-11s3-messaging: Fix messaging classes.Simo Sorce1-1/+1
This has been broken since ff0ac5b0 (May 2007). Basically all messages were belonging to the General class except for CTDB messages. This fixed the message_send_all() function to correctly compute the class, and fixes registrations to include all they need to cope with the fact not all messages are of calss general (registrations rotted a bit because as long as FLAG_MSG_GENERAL was defined the process woould receive all messages). Signed-off-by: Andreas Schneider <asn@samba.org>
2011-08-11s3-messaging: Remove obsolete class.Simo Sorce1-1/+1
The FLAG_MSG_PRINT_NOTIFY class is actually obsolete and never used, as the only message belonging to it is not used either. Signed-off-by: Andreas Schneider <asn@samba.org>
2011-06-09lib/util Bring procid_str() into lib/util as server_id_string()Andrew Bartlett1-7/+0
This is needed for OpenChange, which prints Samba struct server_id values in debug messages. Andrew Bartlett
2011-03-30s3-messages: make ndr_messaging.h part of messages.h.Günther Deschner1-0/+2
Guenther
2011-02-17s3: add server_id.idl and use only autogenerated code.Günther Deschner1-8/+1
Volker, Tridge and other clustering gurus, please check. It is ok to get rid of ifdef CLUSTER_SUPPORT here, right ? Why was unique_id not marshalled at all ? Guenther
2010-09-26s3: Remove talloc_autofree_context() from messaging_tdb_parent_init()Volker Lendecke1-1/+1
2010-08-31s3: messaging_ctdbd_connection() was only called with procid_self()Volker Lendecke1-1/+1
Eventually we'll get this right...
2010-07-05s3: Add messaging_server_idVolker Lendecke1-0/+2
2010-07-05s3: Pass procid_self() explicitly to messaging_ctdbd_connection()Volker Lendecke1-1/+1
2010-07-04s3: Re-initialize the server_id in messaging_reinitVolker Lendecke1-1/+2
2010-03-25s3: Make sure our CLEAR_IF_FIRST optimization works for messaging.tdbVolker Lendecke1-0/+2
In the child, we fully re-open messaging.tdb, which leads to one fcntl lock for CLEAR_IF_FIRST detection per smbd. This opens the tdb in the parent and holds it, so that tdb_reopen_all correctly catches the CLEAR_IF_FIRST bit.
2010-03-10s3: Fix a long-standing problem with recycled PIDsVolker Lendecke1-0/+1
When a samba server process dies hard, it has no chance to clean up its entries in locking.tdb, brlock.tdb, connections.tdb and sessionid.tdb. For locking.tdb and brlock.tdb Samba is robust by checking every time we read an entry from the database if the corresponding process still exists. If it does not exist anymore, the entry is deleted. This is not 100% failsafe though: On systems with a limited PID space there is a non-zero chance that between the smbd's death and the fresh access, the PID is recycled by another long-running process. This renders all files that had been locked by the killed smbd potentially unusable until the new process also dies. This patch is supposed to fix the problem the following way: Every process ID in every database is augmented by a random 64-bit number that is stored in a serverid.tdb. Whenever we need to check if a process still exists we know its PID and the 64-bit number. We look up the PID in serverid.tdb and compare the 64-bit number. If it's the same, the process still is a valid smbd holding the lock. If it is different, a new smbd has taken over. I believe this is safe against an smbd that has died hard and the PID has been taken over by a non-samba process. This process would not have registered itself with a fresh 64-bit number in serverid.tdb, so the old one still exists in serverid.tdb. We protect against this case by the parent smbd taking care of deregistering PIDs from serverid.tdb and the fact that serverid.tdb is CLEAR_IF_FIRST. CLEAR_IF_FIRST does not work in a cluster, so the automatic cleanup does not work when all smbds are restarted. For this, "net serverid wipe" has to be run before smbd starts up. As a convenience, "net serverid wipedbs" also cleans up sessionid.tdb and connections.tdb. While there, this also cleans up overloading connections.tdb with all the process entries just for messaging_send_all(). Volker
2009-01-22s3:messages: finally make message_dispatch() staticStefan Metzmacher1-1/+0
metze
2008-10-12Share data_blob implementation.Jelmer Vernooij1-4/+3
2008-09-12messaging: move types to IDL.Günther Deschner1-85/+0
Guenther (This used to be commit 6c346d0eb20af5ba9b09f30319420f7c91480da6)
2008-05-27Allow server manager to close open files selected by id.Jeremy Allison1-0/+4
Jeremy. (This used to be commit 7eeed8bb41059ec2bddedb6a71deddeec7f33af2)
2008-04-12messaging: add MSG_DBWRAP_TDB2_CHANGES flagStefan Metzmacher1-0/+3
metze (This used to be commit 7418c3ab1d8f18403f5a43817b2cc14e15090fca)
2008-04-12messaging: add FLAG_MSG_DBWRAP message class flagStefan Metzmacher1-0/+2
metze (This used to be commit ee6325495f48bab43a37d740a6eca57192004d57)
2008-01-24Add dump-domain-list command for debugging winbindd's domain_list.Günther Deschner1-0/+1
Guenther (This used to be commit 10fa43f2840899c0854763e55b9174827c522a5b)
2007-10-18RIP BOOL. Convert BOOL -> bool. I found a few interestingJeremy Allison1-1/+1
bugs in various places whilst doing this (places that assumed BOOL == int). I also need to fix the Samba4 pidl generation (next checkin). Jeremy. (This used to be commit f35a266b3cbb3e5fa6a86be60f34fe340a3ca71f)
2007-10-10r24843: Add a "validate-cache" control message to winbindd.Michael Adam1-0/+1
So there is a new subcommand "smbcontrol winbindd validate-cache" now. This change provides the infrastructure: The function currently returns "true" unconditionally. The call of a real cache validation function will be incorporated in subsequent changes. Michael (This used to be commit ef92d505c04397614cb0dd5ede967e9017a5e302)
2007-10-10r24021: use MSG_BROADCAST_PID_STR as value for broadcast messagesStefan Metzmacher1-1/+5
to fix the cluster case vl: please check, if this works with clustering = no metze (This used to be commit 9d4104b8d5773537f2271f7be1439f1da1e0bf42)
2007-10-10r23784: use the GPLv3 boilerplate as recommended by the FSF and the license textAndrew Tridgell1-2/+1
(This used to be commit b0132e94fc5fef936aa766fb99a306b3628e9f07)
2007-10-10r23779: Change from v2 or later to v3 or later.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 407e6e695b8366369b7c76af1ff76869b45347b3)
2007-10-10r23563: Add dump-event-list command to smbcontrol.Günther Deschner1-0/+3
Guenther (This used to be commit 0d956a8e45cd4421cddb8e077e1960dafac3a4d0)
2007-10-10r23410: Merge the core of the cluster code.Volker Lendecke1-0/+36
I'm 100% certain I've forgotten to merge something, but the main code should be in. It's mainly in dbwrap_ctdb.c, ctdbd_conn.c and messages_ctdbd.c. There should be no changes to the non-cluster case, it does survive make test on my laptop. It survives some very basic tests with ctdbd enables, I did not do the full test suite for clusters yet. Phew... Volker (This used to be commit 15553d6327a3aecdd2b0b94a3656d04bf4106323)
2007-10-10r23204: Add MSG_SMB_BRL_VALIDATE. Tridge, this is a bit different from your bzrVolker Lendecke1-0/+5
branch, please check if it fulfils your needs. Two changes: The validation is not done inside the brlock.c traverse_fn, it's done as a separate routine. Secondly, this patch does not call the checker routines in smbcontrol directly but depends on a running smbd. (This used to be commit 7e39d77c1f90d9025cab08918385d140e20ca25b)
2007-10-10r23117: Factor out local messaging.Volker Lendecke1-2/+34
This removes message_block / message_unblock. I've talked to Jeremy and Günther, giving them my reasons why I believe they have no effect. Neither could come up with a counter-argument, so they go :-) (This used to be commit a925e0991ffbaea4a533bab3a5d61e5d367d46c8)
2007-10-10r23112: Trim down the message.c API slightly: The messages_pending_for_pid ↵Volker Lendecke1-51/+63
is now replaced by MSG_FLAG_LOWPRIORITY or'ed into the msg_type. To enable this, changed the msg_type definitions to hexadecimal. This way we could theoretically add the MSG_FLAG_NODUPLICATES again, but I would rather not do this, because that one is racy and can't be guaranteed at all. (This used to be commit 3f5eb8a9600839a9f9c44c553f0bda6df22b30b0)
2007-10-10r23055: Rewrite messages.c to use auto-generated marshalling in the tdb. I'mVolker Lendecke1-0/+33
doing this because for the clustering the marshalling is needed in more than one place, so I wanted a decent routine to marshall a message_rec struct which was not there before. Tridge, this seems about the same speed as it used to be before, the librpc/ndr overhead in my tests was under the noise. Volker (This used to be commit eaefd00563173dfabb7716c5695ac0a2f7139bb6)
2007-10-10r22736: Start to merge the low-hanging fruit from the now 7000-line cluster ↵Volker Lendecke1-9/+1
patch. This changes "struct process_id" to "struct server_id", keeping both is just too much hassle. No functional change (I hope ;-)) Volker (This used to be commit 0ad4b1226c9d91b72136310d3bbb640d2c5d67b8)
2007-10-10r21079: Minimizing diff: Adopt the Samba4 style ChangeNotify flags.Volker Lendecke1-0/+4
Volker (This used to be commit a3c1069b0c3da914e2ac7337fd9e924b1c811d39)
2007-10-10r21074: Preparation for the import of samba4 notify: Add the file notify.idl ↵Volker Lendecke1-0/+8
and the resulting marshalling/unmarshalling routines in gen_ndr/ Volker (This used to be commit a2ea54c23456925a8ed317edb1adf82d074041fc)
2007-10-10r20916: Add in the delete on close final fix - but only enabledJeremy Allison1-0/+1
with -DDEVELOPER. Jeremy. (This used to be commit 7f817067a70930ee3502ea3373173e0c23733253)
2007-10-10r20854: Ok, now I think we're at a point where looking at notify starts to ↵Volker Lendecke1-0/+1
make sense again :-) Volker (This used to be commit 5533cdeec1b0cdee39b1d89e2320587dc9281ee6)
2007-10-10r20636: Remove notify leftoverVolker Lendecke1-1/+0
(This used to be commit a174b49173e7185abb89e605e667e64e8dd87454)
2007-10-10r20394: This is a *VERY* early start of my work on notify.Volker Lendecke1-0/+1
Checking in because Jeremy was bugging me. Potentially this becomes quite intrusive, I'm not sure if I should open a temporary branch for this. Jeremy, Jerry, do you think 3_0 is the right place for this? Volker (This used to be commit bcf5c751cbe203c00814642e26440cf88f300bce)
2007-10-10r20140: Make online/offline detection completely asynchronous.Jeremy Allison1-0/+2
Now I've done this I might be able to reduce the probe timeout and reduce the backoff algorithm, going back to checking every cache time seconds (5 mins by default), as the parent or forked domain child will never block. Jeremy. (This used to be commit d0add5f946cf63ea43067e8e935876b5346d11de)
2007-10-10r17098: Samba3 now cleanly passes Samba4 RAW-LOCK tortureJeremy Allison1-0/+1
test. Phew - that was painful :-). But what it means is that we now implement lock cancels and I can add lock cancels into POSIX lock handling which will fix the fast/slow system call issue with cifsfs ! Jeremy. (This used to be commit f1a9cf075b87c76c032d19da0168424c90f6cb3c)
2007-10-10r15428: Add "smbcontrol winbind onlinestatus" for debugging purpose.Günther Deschner1-0/+1
Guenther (This used to be commit 9e15b1659c105b0be846e8f71c27b20eab961bd2)
2007-10-10r14898: This change is an attempt to improve the quality of the information thatJames Peach1-0/+1
is produced when a process exits abnormally. First, we coalesce the core dumping code so that we greatly improve our odds of being able to produce a core file, even in the case of a memory fault. I've removed duplicates of dump_core() and split it in two to reduce the amount of work needed to actually do the dump. Second, we refactor the exit_server code path to always log an explanation and a stack trace. My goal is to always produce enough log information for us to be able to explain any server exit, though there is a risk that this could produce too much log information on a flaky network. Finally, smbcontrol has gained a smbd fault injection operation to test the changes above. This is only enabled for developer builds. (This used to be commit 56bc02d64498eb3faf89f0c5452b9299daea8e95)
2007-10-10r13316: Let the carnage begin....Gerald Carter1-0/+2
Sync with trunk as off r13315 (This used to be commit 17e63ac4ed8325c0d44fe62b2442449f3298559f)