summaryrefslogtreecommitdiffstats
path: root/source3/smbd/server.c
Commit message (Collapse)AuthorAgeFilesLines
* s3-smbd: Remove obsolete smbd_set_server_fd().Andreas Schneider2011-07-041-7/+6
| | | | Signed-off-by: Andrew Bartlett <abartlet@samba.org>
* s3:smbd do not panic when CTDB is unhealthy (Bug #8278)Christian Ambach2011-06-301-0/+9
| | | | | | | | when CTDB is unhealthy, log a message and exit cleanly instead of creating a core file Autobuild-User: Christian Ambach <ambi@samba.org> Autobuild-Date: Thu Jun 30 13:18:12 CEST 2011 on sn-devel-104
* s3-param prepare for some lp_ functions to return constAndrew Bartlett2011-06-011-1/+1
|
* s3-globals Remove smbd_event_context() (use server_event_context())Andrew Bartlett2011-05-311-26/+21
| | | | | | | | This has been a wrapper around server_event_context() for some time now, and removing this from dummmysmbd.c assists with library dependencies. Andrew Bartlett
* s3-smbd provide struct smbd_server_connection * to conn_snum_usedAndrew Bartlett2011-05-311-1/+1
| | | | | | | | | | | | | | | | This provides the 'sconn' parameter to this key functions, that is currently duplicated in dummysmbd.c, which causes duplicate symbol issues in the waf build. This has natrually caused a number of consequential changes across the codebase, includning not passing a messaging context into initial reload_services(): This causes problems because the global smbd_server_connection isn't yet set up, as there isn't a connection here, just the initial process. Andrew Bartlett
* s3-lib Replace StrCaseCmp() with strcasecmp_m()Andrew Bartlett2011-05-181-2/+2
| | | | | | | strcasecmp_m() never needs to call to talloc, and via next_codepoint() still has an ASCII fast-path bypassing iconv() calls. Andrew Bartlett
* s3-smbd: expose smbd_set_server_fd()Andrew Tridgell2011-05-081-29/+0
| | | | | | | | | | this allows the fd to be setup by subsystems that want to use the s3 server core code Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org> Autobuild-User: Andrew Bartlett <abartlet@samba.org> Autobuild-Date: Sun May 8 12:01:13 CEST 2011 on sn-devel-104
* s3-build: remove some unused headers.Günther Deschner2011-04-291-1/+0
| | | | Guenther
* s3: only include smb profiling where needed.Günther Deschner2011-04-141-0/+1
| | | | | | | Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Thu Apr 14 01:31:39 CEST 2011 on sn-devel-104
* Fix bug #8047 - mdns registration doesn't work if "interfaces" is used in ↵Marc A. Dahlhaus2011-04-011-0/+7
| | | | | | | smb.conf Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Fri Apr 1 23:15:34 CEST 2011 on sn-devel-104
* s3-messages: make ndr_messaging.h part of messages.h.Günther Deschner2011-03-301-1/+0
| | | | Guenther
* s3-messages: only include messages.h where needed.Günther Deschner2011-03-301-0/+1
| | | | Guenther
* s3-auth: smbd needs auth.hGünther Deschner2011-03-301-0/+1
| | | | Guenther
* s3: include smbd/smbd.h where needed.Günther Deschner2011-03-301-0/+1
| | | | Guenther
* s3-passdb: use passdb headers where needed.Günther Deschner2011-03-301-0/+1
| | | | Guenther
* s3-includes: only include system/filesys.h when needed.Günther Deschner2011-03-301-0/+1
| | | | Guenther
* s3-spoolssd: Start the spoolss service correctly.Andreas Schneider2011-03-291-1/+1
| | | | Signed-off-by: Günther Deschner <gd@samba.org>
* s3-spoolssd: Pass down event and messanging context.Andreas Schneider2011-03-291-2/+4
| | | | Signed-off-by: Günther Deschner <gd@samba.org>
* s3:spoolssd Start spoolss from smbdSimo Sorce2011-03-291-0/+15
| | | | Signed-off-by: Günther Deschner <gd@samba.org>
* s3-config: say which config file we failed to openAndrew Tridgell2011-03-231-1/+1
| | | | saves having to strace it to work that out
* fault: get fault.c ready for use by s4Andrew Tridgell2011-03-231-1/+1
| | | | | this moves the s3 specific dumpcore code into source3/lib/dumpcore.c, and uses a function pointer to setup which smb_panic call to use
* s3-fault: removed the cont_fn from fault_setup()Andrew Tridgell2011-03-221-1/+1
| | | | | | | | | | cont_fn() was supposed to be a way to continue after a seg fault. It could never be called however, as smb_panic() from fault_report() could never return, as dump_core() never returns at the end of smb_panic() Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Tue Mar 22 05:07:58 CET 2011 on sn-devel-104
* s3-rpc_server: Start the Endpoint Mapper Dameon if enabled.Andreas Schneider2011-03-081-0/+15
| | | | | | Endpoint Mapper is still disabled by default! Signed-off-by: Günther Deschner <gd@samba.org>
* s3-server_id: only include server_id where needed.Günther Deschner2011-03-021-0/+1
| | | | Guenther
* s3-smbd: Pass tevent context to messaging functions.Andreas Schneider2011-02-281-4/+11
| | | | | Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Mon Feb 28 19:00:08 CET 2011 on sn-devel-104
* s3: smbcontrol to notify smbd about idmap changesGregor Beck2011-02-281-0/+2
| | | | | Autobuild-User: Michael Adam <obnox@samba.org> Autobuild-Date: Mon Feb 28 14:07:23 CET 2011 on sn-devel-104
* s3-printing: only include printing where really needed.Günther Deschner2011-02-221-0/+1
| | | | Guenther
* s3-printing: fix pcacp prototypes and includes.Günther Deschner2011-02-221-0/+1
| | | | Guenther
* s3-rpc_server: Rename srv_rpc_register.c.Andreas Schneider2011-02-211-1/+1
|
* s3-rpc_server: Rename srv_rpc_register.Andreas Schneider2011-02-211-1/+1
|
* s3-rpc_server: Pass tevent_context to dcerpc endpoints.Andreas Schneider2011-02-211-1/+1
|
* s3: Convert init_system_info to NTSTATUSVolker Lendecke2011-02-201-2/+4
|
* s3: increase the log level for missing PIDs on SIGCHLDDavid Disseldorp2011-02-171-1/+2
| | | | | | | | | | | | | | | | | | | Since the fix for bso#7836, the parent smbd is responsible for maintaining an up-to-date printcap cache. It does this by forking a child process to asynchronously fetch printcap data from CUPS. When the child process exits after fetching all printcap data, the parent smbd is sent SIGCHLD. This triggers smbd_sig_chld_handler() which looks for the exited process PID on a "children" list. Child smbd process PIDs are added to the "children" list to ensure cleanup on unclean shutdown and log level change notification messages. Printcap update process PIDs are not added to the list as they do not maintain any state that requires cleanup, nor do they wait on tevent for messages. Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Thu Feb 17 11:11:45 CET 2011 on sn-devel-104
* s3-smbd: Added a function to setup rpc services.Andreas Schneider2011-02-021-90/+2
| | | | | Move the complete setup of the rpc service to its own file and use callbacks to register at the endpoint mapper.
* s3-epmapper: Added a endpoint mapper skeleton.Andreas Schneider2011-02-021-0/+1
|
* s3-printing: Initiate pcap reload from parent smbdDavid Disseldorp2011-01-071-0/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit 7022554, smbds share a printcap cache (printer_list.tdb), therefore ordering of events between smbd processes is important when updating printcap cache information. Consider the following two process example: 1) smbd1 receives HUP or printcap cache time expiry 2) smbd1 checks whether pcap needs refresh, it does 3) smbd1 marks pcap as refreshed 4) smbd1 forks child1 to obtain cups printer info 5) smbd2 receives HUP or printcap cache time expiry 6) smbd2 checks whether pcap needs refresh, it does not (due to step 3) 7) smbd2 reloads printer shares prior to child1 completion (stale pcap) 8) child1 completion, pcap cache (printer_list.tdb) is updated by smbd1 9) smbd1 reloads printer shares based on new pcap information In this case both smbd1 and smbd2 are reliant on the pcap update performed on child1 completion. The prior commit "reload shares after pcap cache fill" ensures that smbd1 only reloads printer shares following pcap update, however smbd2 continues to present shares based on stale pcap data. This commit addresses the above problem by driving pcap cache and printer share updates from the parent smbd process. 1) smbd0 (parent) receives a HUP or printcap cache time expiry 2) smbd0 forks child0 to obtain cups printer info 3) child0 completion, pcap cache (printer_list.tdb) is updated by smbd0 4) smbd0 reloads printer shares 5) smbd0 notifies child smbds of pcap update via message_send_all() 6) child smbds read fresh pcap data and reload printer shares This architecture has the additional advantage that only a single process (the parent smbd) requests printer information from the printcap backend. Use time_mono in housekeeping functions As suggested by Björn Jacke.
* s3-printing: reload shares after pcap cache fillDavid Disseldorp2011-01-071-1/+2
| | | | | | | | | | | | | | | | Since commit eada8f8a, updates to the cups pcap cache are performed asynchronously - cups_cache_reload() forks a child process to request cups printer information and notify the parent smbd on completion. Currently printer shares are reloaded immediately following the call to cups_cache_reload(), this occurs prior to smbd receiving new cups pcap information from the child process. Such behaviour can result in stale print shares as outlined in bug 7836. This fix ensures print shares are only reloaded after new pcap data has been received. Pair-Programmed-With: Lars Müller <lars@samba.org>
* s3-rpcecho: Only register rpcecho in the developer build.Andreas Schneider2011-01-041-0/+2
| | | | | Autobuild-User: Andreas Schneider <asn@samba.org> Autobuild-Date: Tue Jan 4 18:56:38 CET 2011 on sn-devel-104
* s3-smbd: Call all the rpc services in the right order.Andreas Schneider2011-01-041-5/+41
|
* s3:smbd: remove some commented out legacy codeMichael Adam2010-12-021-5/+0
| | | | | Autobuild-User: Michael Adam <obnox@samba.org> Autobuild-Date: Thu Dec 2 01:18:19 CET 2010 on sn-devel-104
* s3: Allow disabling of mdns registrationsVolker Lendecke2010-11-051-1/+1
| | | | | Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Fri Nov 5 11:24:41 UTC 2010 on sn-devel-104
* s3-debug Move 'load_case_tables()' before lp_set_cmdline() and popt callsAndrew Bartlett2010-11-021-2/+2
| | | | | | | | | | The problem here is that we cannot run lp_set_cmdline() (directly or indirectly via the popt helpers) until load_case_tables() has been run. However, load_case_tables does not have auto-initialisation, so we must init it once, and once only. Andrew Bartlett
* s3-debug Impove setup_logging() to specify logging to stderrAndrew Bartlett2010-11-021-1/+5
| | | | | | | | This change improves the setup_logging() API so that callers which wish to set up logging to stderr can simply ask for it, rather than directly modify the dbf global variable. Andrew Bartlett
* s3: Call printer_list_parent_init in the parentVolker Lendecke2010-10-081-0/+5
| | | | Simo, please check!
* Move talloc_enable_null_tracking() to the s3 daemonsVolker Lendecke2010-10-081-1/+7
|
* s3: Lift smbd_messaging_context() from open_sockets_smbd()Volker Lendecke2010-09-281-16/+14
|
* s3: Remove talloc_autofree_context() from files.cVolker Lendecke2010-09-281-2/+5
|
* s3: Remove talloc_autofree_context() from notify_internal_parent_init()Volker Lendecke2010-09-261-1/+1
|
* s3: Remove talloc_autofree_context() from serverid_parent_init()Volker Lendecke2010-09-261-1/+1
|
* s3: Remove talloc_autofree_context() from messaging_tdb_parent_init()Volker Lendecke2010-09-261-1/+1
|