summaryrefslogtreecommitdiff
path: root/source3/smbd/server.c
AgeCommit message (Collapse)AuthorFilesLines
2009-01-29s3:smbd: make smbd_open_one_socket() staticMichael Adam1-3/+3
Michael
2009-01-29s3:smbd: ignore open_socket_in() failuresStefan Metzmacher1-1/+4
This restores the pre e0232934fbf69a9e72de1d9844b14d70b34a2d6a behavior. metze
2009-01-27s3:smbd: wait for new connection via fd eventsStefan Metzmacher1-211/+227
metze
2009-01-27s3:smbd: make mdns registration event driven.Stefan Metzmacher1-15/+10
metze
2009-01-27s3:smbd: make inetd code path more clearStefan Metzmacher1-24/+20
metze
2009-01-27s3:smbd: remove pointless respond_to_all_remaining_local_messages() functionStefan Metzmacher1-2/+0
This the process_kernel_oplock() function never response to messages, it only generates messages to ourself. metze
2009-01-27s3:smbd: use signal events for SIGTERM, SIGHUP and SIGCHLDStefan Metzmacher1-76/+51
metze
2009-01-27s3:smbd: move all code that handles a client connection into smbd_process()Stefan Metzmacher1-212/+0
metze
2009-01-27s3:smbd: we should setup the client socket in the same way in all code pathesStefan Metzmacher1-21/+15
We should behave the same in inetd, interactive and deamon modes. metze
2009-01-27s3:namecache: remove unused namecache_shutdown() functionStefan Metzmacher1-2/+0
metze
2009-01-22s3:smbd: we don't need to call message_dispatch() anymore it's event ↵Stefan Metzmacher1-3/+0
triggered now metze
2009-01-22s3: always call run_events() before and after sys_select()Stefan Metzmacher1-4/+8
And always setup the fd events. metze
2009-01-20Remove some unused codeVolker Lendecke1-3/+0
2009-01-16s3:cluster: fix ctdb ipv6 supportStefan Metzmacher1-3/+1
We need to use CTDB_CONTROL_TCP_CLIENT instead of CTDB_CONTROL_TCP_ADD. CTDB_CONTROL_TCP_CLIENT has support for 2 modes in newer ctdb versions: - with struct ctdb_control_tcp it only supports ipv4. - with struct ctdb_control_tcp_addr it supports ipv4 and ipv6. You need new header files which defines struct ctdb_control_tcp_addr, but at runtime it should be fine to work against older ctdb versions (<= 1.0.68). metze
2009-01-15s3: make better use of ccache by not including version.h in every C-file.Michael Adam1-1/+1
version.h changes rather frequently. Since it is included via includes.h, this means each C file will be a cache miss. This applies to the following situations: * When building a new package with a new Samba version * building in a git branch after calling mkversion.sh after a new commit (i.e. virtually always) This patch improves the situation in the following way: * remove inlude "version.h" from includes.h * Use samba_version_string() instead of SAMBA_VERSION_STRING in files that use no other macro from version.h instead of SAMBA_VERSION_STRING. * explicitly include "version.h" in those files that use more macros from "version.h" than just SAMBA_VERSION_STRING. Michael
2009-01-08s3:smbd: move all globals and static variables in globals.[ch]Stefan Metzmacher1-39/+23
The goal is to move all this variables into a big context structure. metze
2009-01-08s3:smbd: variables in a main() don't need to be staticStefan Metzmacher1-7/+7
metze
2009-01-08s3:smbd: open_sockets_smbd() don't need a static variable arrount atexit()Stefan Metzmacher1-7/+1
open_sockets_smbd() is only called once. metze
2009-01-05clean event context after child is forked.Bo Yang1-2/+5
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2008-12-30s3 build: Fix warningTim Prouty1-0/+2
2008-12-30s3:cluster: register the client connection via CTDB_CONTROL_TCP_ADDStefan Metzmacher1-3/+6
This means we correctly pass IPv6 addresses too. (CTDB_CONTROL_TCP_CLIENT was IPv4 only) metze
2008-12-05Fix bug #5944 - nmbd does not boot if socket adress = "" is defined in smb.confYasuma Takeda1-3/+2
2008-11-06Make us clean under valgrind --leak-check=full by using ↵Jeremy Allison1-3/+3
talloc_autofree_context() instead of NULL. Remove the code in memcache that does a TALLOC_FREE on stored pointers. That's a disaster waiting to happen. If you're storing talloc'ed pointers, you can't know their lifecycle and they should be deleted when their parent context is deleted, so freeing them at some arbitrary point later will be a double-free. Jeremy.
2008-11-01Remove sys_chroot() - libreplace already provides an alternative.Jelmer Vernooij1-1/+1
2008-10-18s3-build: fix the build of smbd.Günther Deschner1-1/+1
Guenther
2008-10-18Use separate make variables for libutil and libcrypto.Jelmer Vernooij1-2/+2
2008-10-03Simply our main loop processing. A lot :-). Correctly use events for all the ↵Jeremy Allison1-0/+31
previous "special" cases. A step on the way to adding signals to the events and being able to merge the S3 event system with the S4 one. Jeremy.
2008-08-14Fix for bug #5688 from SATOH Fumiyasu <fumiyas@osstech.co.jp>. LPQ process ↵Jeremy Allison1-1/+2
is orphaned if socket address parameter is invalid. If the "socket address" parameter is a null string that is an invalid value for Samba 3.2 but valid for Samba 3.0. Jeremy. (This used to be commit c65726d418601cdc86202c0371615e4f7f3d843c)
2008-08-13smbd: prevent smbd from panicing with "clustering = no" but ↵Michael Adam1-1/+3
--with-cluster-support Michael (This used to be commit a687949d19ba9690f96e7869aa22e4d87840640e)
2008-08-13added a explanatory comment on tcon checkAndrew Tridgell1-0/+4
(This used to be commit f2ab2cebb9b81453dc0b6370288b85909182ae49)
2008-08-13ensure we exit with non-zero status on EOF on socket, so the parentAndrew Tridgell1-3/+8
can trigger a brlock db cleanup (This used to be commit bbd49f9e1c4b50c4a596fb991f3306e1e90c0177)
2008-08-13fixed child exit handling and IP release handlingAndrew Tridgell1-1/+3
(This used to be commit 6fe27d296c389473c24e8c627a61bd56b364ad9f)
2008-08-13log unclean shutdownsAndrew Tridgell1-0/+1
(This used to be commit 30b83245a22ebd5e4fa4739dd2aa1805373a7eb2)
2008-08-13register the ctdbd reconfigure messageAndrew Tridgell1-0/+4
(This used to be commit 9d3217bb28765e107c230fb90b578dcc6f5d4375)
2008-08-13first cut at adding full transactions for ctdb to samba3Andrew Tridgell1-7/+0
(This used to be commit f91a3e0f7b7737c1d0667cd961ea950e2b93e592)
2008-06-26smbd: untangle logic in smbd_messaging_context() slightly.Michael Adam1-2/+5
Michael (This used to be commit fae4c21b14b9d288e06f6b4b4e1527e2c6d58dca)
2008-06-26smbd: don't panic if messaging_init() fails but return NULLMichael Adam1-1/+1
leaving panic or more appropriate action to callers. This can for instance happen in a clustered setup, when ctdb is not running. This allows for a more defined behaviour, reducing chicken-egg-problems. Michael (This used to be commit 3b6541ff483d5fea4fd30bb6a01a560c05028d4e)
2008-05-27Allow server manager to close open files selected by id.Jeremy Allison1-0/+2
Jeremy. (This used to be commit 7eeed8bb41059ec2bddedb6a71deddeec7f33af2)
2008-04-23Fix CLEAR_IF_FIRST handling of messages.tdbVolker Lendecke1-2/+3
We now open messages.tdb even before we do the become_daemon. become_daemon() involves a fork and an immediate exit of the parent, thus the parent_is_longlived argument must be set to false in this case. The parent is not really long lived :-) (This used to be commit 4f4781c6d17fe2db34dd5945fec52a7685448aec)
2008-04-18smbd: create the messaging conntext earlierStefan Metzmacher1-11/+16
metze (This used to be commit 658d8475336c4397e0dad341f216baf9e1eb6aaf)
2008-04-18smbd: call reinit_after_fork() in the needed placesStefan Metzmacher1-16/+6
metze (This used to be commit 425b3513a45cf98b53235470a3536be86d56d1c2)
2008-04-18smbd: merge "smbd:backgroundqueue=no" option from the v3-0-ctdb treeStefan Metzmacher1-2/+4
metze (This used to be commit 16d295d466eb18e3bccce6fb26d53012d5f2c3e8)
2008-04-13registry: rename init_registry() to registry_init_full() for consistency.Michael Adam1-1/+1
Michael (This used to be commit 14d82708d4499b48830d3dd25a0133f00a39d030)
2008-04-13registry: change init_registry() to return WERROR instead of bool.Michael Adam1-1/+1
Michael (This used to be commit 0b196095dbbc29c796cb0742fe6e57a421e9596b)
2008-04-12dbwrap: wait for tdb2 change notifies in smbd, nmbd and winbinddStefan Metzmacher1-1/+5
metze (This used to be commit 64450cc1e441355aa8925b7183e90872eeab20b1)
2008-04-08Destroy DMAPI session when main smbd daemon exits.Alexander Bokovoy1-0/+9
DMAPI session is precious resource maintained at kernel level. We open one of them and use across multiple smbd daemons but once last of them exits, DMAPI session needs to be destroyed. There are some HSM implementations which fail to shutdown when opened DMAPI sessions left. Ensure we shutdown our session when it is really not needed anymore. This is what recommended by DMAPI specification anyway. (This used to be commit a0cefd44009d414fa00ec6e08c70d21b74acdbcb)
2008-03-20Port 3c1f1f0797e from 3-0-ctdbroot1-3/+57
We need to inform ctdb about the client's TCP connection so that after a fail over ctdbd can trigger the client to reconnect very quickly (This used to be commit ddc989886deff173b8a2a2a753a896770efe7545)
2008-03-18[samba-3-0-ctdb.tridge @ tridge@samba.org-20070602053809-kpw5kjkcyjs8yjbl]Andrew Tridgell1-1/+1
suppress that darn message (cherry picked from commit 542e46a21898f6fcc8a0aeb63925607a60e0b99f) (This used to be commit 5e8c624c9c9775f255632717e6898d5f190ba51b)
2008-02-18Check return code of secrets_init() function.Tim Potter1-1/+2
(This used to be commit 2b1eead269e95142576d0c8c259874324ba83502)
2008-01-18Merge DMAPI fixes from CTDB SambaAlexander Bokovoy1-6/+0
(This used to be commit cf1f90ad7a79dbe5926018790bb50d4e3b36cc7b)