summaryrefslogtreecommitdiffstats
path: root/packaging/Debian
diff options
context:
space:
mode:
Diffstat (limited to 'packaging/Debian')
-rw-r--r--packaging/Debian/debian/changelog59
-rw-r--r--packaging/Debian/debian/config.cache10
-rw-r--r--packaging/Debian/debian/libpam-smbpass.docs1
-rw-r--r--packaging/Debian/debian/patches/Makefile.in.patch7
-rw-r--r--packaging/Debian/debian/patches/fhs.patch19
-rw-r--r--packaging/Debian/debian/patches/loadparm.patch13
-rw-r--r--packaging/Debian/debian/patches/lpq_parse.c.patch6
-rw-r--r--packaging/Debian/debian/patches/samba.patch6
-rw-r--r--packaging/Debian/debian/patches/smbclient-xfer-speed.patch4
-rw-r--r--packaging/Debian/debian/patches/smbmount-nomtab.patch12
-rwxr-xr-xpackaging/Debian/debian/rules6
-rw-r--r--packaging/Debian/debian/samba-common.postinst7
-rw-r--r--packaging/Debian/debian/samba-common.postrm1
-rw-r--r--packaging/Debian/debian/samba.init60
14 files changed, 95 insertions, 116 deletions
diff --git a/packaging/Debian/debian/changelog b/packaging/Debian/debian/changelog
index 9548b5933c7..bf9d516b186 100644
--- a/packaging/Debian/debian/changelog
+++ b/packaging/Debian/debian/changelog
@@ -1,55 +1,34 @@
-samba (2.2.5-0.1debian) unstable; urgency=low
+samba (2.2.6-1.woody) stable; urgency=low
- * This is a locally-built version of Samba for Debian. Do not pester
- the Samba Team with questions about Debian packaging. Contact the
- Debian Samba maintainers <samba@packages.debian.org> instead.
+ * New upstream version.
- -- Debian User <somebody@somewhere.com> Mon, 17 Jun 2002 23:22:36 -0400
+ -- Eloy A. Paris <peloy@debian.org> Sun, 13 Oct 2002 02:33:32 -0400
-samba (2.2.4+2.2.5-1) unstable; urgency=low
+samba (2.2.5-1.woody) stable; urgency=low
- * New upstream release.
- * Remove patches/parse_spoolss.patch, now included upstream.
- * Fixed thinko WRT POSIX ACL support, which we "half-enabled" in
- 2.2.4-1. We don't use POSIX ACL support ourselves, so we'd
- appreciate reports from those using this feature so we can
- be sure this works.
+ * Upload latest stable Samba release to woody.
+ - includes improved NT printing support (closes: #157406)
* Fix the filename-matching algorithm used for smbtar's 'exclude'
functionality. (closes: #131571)
+ * Remove patches/srv_spoolss_nt.patch, now included upstream.
+
+ -- Steve Langasek <vorlon@debian.org> Fri, 23 Aug 2002 17:20:08 -0500
+
+samba (2.2.3a-8) stable; urgency=low
+
+ * maintainer script fixes backported from sid.
+ * reorder postinst, so that installing samba-common from scratch loads
+ the debconf answers properly (closes: #151985).
* Look for secrets.tdb in /var/lib/samba, and handle in the postinst.
This is not really a config file, because users don't edit it.
(closes: #147429)
- * Doxygen fix for libsmbclient.h, thanks to Tommi Komulainen
- <Tommi.Komulainen@iki.fi> for the patch. (closes: #144847)
-
- -- Eloy A. Paris <peloy@debian.org> Tue, 28 May 2002 11:33:51 -0400
-
-samba (2.2.4-1) unstable; urgency=low
-
- * New upstream release (closes: #144713)
- * Building with POSIX ACL support (closes: #137819)
- * Include samples, exclude INSTALL from libpam-smbpass (closes: #145055)
- * Compile with --with-automount, for NIS homedir support (closes: #123396)
- * Add a proper 'flags' field to the mount entry we write to /etc/mtab;
- fixes a display bug with mount (closes: #140397)
- * Added logic to /etc/init.d/samba so a help message is printed out
- when Samba is running from inetd _and_ we are not booting, i.e. the
- user called the init script manually. Thanks to Francesco
- Potorti <pot@gnu.org> for the suggestion on how to implement this.
- (Closes: #139807, #140204)
* samba.postinst: added logic so we don't call /etc/init.d/samba if
we are running from inetd (this prevents the stupid help message
to be printed during package upgrades if we are running from inetd.)
- * samba.prerm: idem.
- * /etc/init.d/samba: delete stale PID files after nmbd and smbd are
- stopped. This prevents start-stop-daemon from printing an ugly
- error message when called from '/etc/init.d/samba stop'. I prefer
- this than running start-stop-daemon with --oknodo because
- start-stop-daemon might print other important error messages that with
- --oknodo it would otherwise not print. (Closes: #102187, #109301)
- * Patch from jerry@samba.org to fix parsing of spoolss structures.
+ * Fixed bug in the FHS migration path that causes nmbd to read its
+ state from one location, but write it out to another. (closes: #154210)
- -- Eloy A. Paris <peloy@debian.org> Thu, 23 May 2002 23:16:52 -0400
+ -- Steve Langasek <vorlon@debian.org> Sat, 13 Jul 2002 10:18:56 -0500
samba (2.2.3a-7) unstable; urgency=medium
@@ -98,7 +77,7 @@ samba (2.2.3a-6) unstable; urgency=low
* Bring our shipped smb.conf closer in line with the upstream
defaults: don't twiddle the send/recv buffer sizes, since the Linux
kernel already provides a much better default setting
- (closes: #80966, #80934, #137415, #133477)
+ (closes: #80966, #80934, #137415, #133477)
* Added libnss_wins.so to the winbind package (closes: #137201)
* Updates to README.debian.
diff --git a/packaging/Debian/debian/config.cache b/packaging/Debian/debian/config.cache
index 8872a27b761..c0a70a5b19b 100644
--- a/packaging/Debian/debian/config.cache
+++ b/packaging/Debian/debian/config.cache
@@ -46,6 +46,12 @@ samba_cv_have_setresgid=${samba_cv_have_setresgid=yes}
samba_cv_USE_SETRESUID=${samba_cv_USE_SETRESUID=yes}
+# POSIX ACL support not present in Linux 2.2; not allowed in the
+# Debian packages, even if present on the build machine.
+
+ac_cv_header_sys_acl_h=${ac_cv_header_sys_acl_h=no}
+
+
# Various basic libc/compiler stuff that it's blindingly obvious that
# Linux supports (now watch me get bitten for saying that)
@@ -124,6 +130,8 @@ samba_cv_HAVE_FCNTL_LOCK=${samba_cv_HAVE_FCNTL_LOCK=yes}
# to support transparent userland VFS. We might as well preempt
# any checks for shadowed symbols that are only useful for smbwrapper.
+ac_cv_func___acl=${ac_cv_func___acl=no}
+ac_cv_func__acl=${ac_cv_func__acl=no}
ac_cv_func___chdir=${ac_cv_func___chdir=no}
ac_cv_func__chdir=${ac_cv_func__chdir=no}
ac_cv_func___close=${ac_cv_func___close=no}
@@ -134,6 +142,8 @@ ac_cv_func___dup=${ac_cv_func___dup=no}
ac_cv_func__dup=${ac_cv_func__dup=no}
ac_cv_func___dup2=${ac_cv_func___dup2=no}
ac_cv_func__dup2=${ac_cv_func__dup2=no}
+ac_cv_func___facl=${ac_cv_func___facl=no}
+ac_cv_func__facl=${ac_cv_func__facl=no}
ac_cv_func___fchdir=${ac_cv_func___fchdir=no}
ac_cv_func__fchdir=${ac_cv_func__fchdir=no}
ac_cv_func___fcntl=${ac_cv_func___fcntl=no}
diff --git a/packaging/Debian/debian/libpam-smbpass.docs b/packaging/Debian/debian/libpam-smbpass.docs
index 7d4519542f5..d84796d551b 100644
--- a/packaging/Debian/debian/libpam-smbpass.docs
+++ b/packaging/Debian/debian/libpam-smbpass.docs
@@ -1,3 +1,4 @@
source/pam_smbpass/CHANGELOG
source/pam_smbpass/README
+source/pam_smbpass/INSTALL
source/pam_smbpass/TODO
diff --git a/packaging/Debian/debian/patches/Makefile.in.patch b/packaging/Debian/debian/patches/Makefile.in.patch
index bdc23066a28..e669c4ebada 100644
--- a/packaging/Debian/debian/patches/Makefile.in.patch
+++ b/packaging/Debian/debian/patches/Makefile.in.patch
@@ -1,7 +1,6 @@
-diff -uNr samba-2.2.5pre1.orig/source/Makefile.in samba-2.2.5pre1/source/Makefile.in
---- samba-2.2.5pre1.orig/source/Makefile.in Tue Jun 4 15:54:14 2002
-+++ samba-2.2.5pre1/source/Makefile.in Wed Jun 12 15:25:42 2002
-@@ -714,9 +714,10 @@
+--- samba/source/Makefile.in.orig 2002-10-13 01:43:10.000000000 -0400
++++ samba/source/Makefile.in 2002-10-13 01:43:10.000000000 -0400
+@@ -723,9 +723,10 @@
@$(SHELL) $(srcdir)/script/installswat.sh $(SWATDIR) $(srcdir)
installclientlib:
diff --git a/packaging/Debian/debian/patches/fhs.patch b/packaging/Debian/debian/patches/fhs.patch
index bb28990a210..17777d15f8c 100644
--- a/packaging/Debian/debian/patches/fhs.patch
+++ b/packaging/Debian/debian/patches/fhs.patch
@@ -1,7 +1,7 @@
diff -uNr samba-2.2.5pre1.orig/source/Makefile.in samba-2.2.5pre1/source/Makefile.in
--- samba-2.2.5pre1.orig/source/Makefile.in Wed Jun 12 15:26:50 2002
+++ samba-2.2.5pre1/source/Makefile.in Wed Jun 12 15:30:29 2002
-@@ -83,7 +83,7 @@
+@@ -84,7 +84,7 @@
FLAGS1 = $(CFLAGS) @FLAGS1@ -Iinclude -I$(srcdir)/include -I$(srcdir)/ubiqx -I$(srcdir)/smbwrapper $(CPPFLAGS) -DLOGFILEBASE=\"$(LOGFILEBASE)\"
FLAGS2 = -DCONFIGFILE=\"$(CONFIGFILE)\" -DLMHOSTSFILE=\"$(LMHOSTSFILE)\"
FLAGS3 = -DSWATDIR=\"$(SWATDIR)\" -DSBINDIR=\"$(SBINDIR)\" -DLOCKDIR=\"$(LOCKDIR)\" -DCODEPAGEDIR=\"$(CODEPAGEDIR)\"
@@ -53,9 +53,9 @@ diff -uNr samba-2.2.5pre1.orig/source/include/config.h.in samba-2.2.5pre1/source
diff -uNr samba-2.2.5pre1.orig/source/include/local.h samba-2.2.5pre1/source/include/local.h
--- samba-2.2.5pre1.orig/source/include/local.h Tue Jan 15 10:02:37 2002
+++ samba-2.2.5pre1/source/include/local.h Wed Jun 12 15:30:29 2002
-@@ -189,4 +189,20 @@
- /* Allocation roundup. */
- #define SMB_ROUNDUP_ALLOCATION_SIZE 0x100000
+@@ -191,4 +191,20 @@
+ /* Max number of jobs per print queue. */
+ #define PRINT_MAX_JOBID 10000
+/* FHS-compatible directory defines */
+#ifdef FHS_COMPATIBLE
@@ -77,7 +77,7 @@ diff -uNr samba-2.2.5pre1.orig/source/include/local.h samba-2.2.5pre1/source/inc
diff -uNr samba-2.2.5pre1.orig/source/lib/util.c samba-2.2.5pre1/source/lib/util.c
--- samba-2.2.5pre1.orig/source/lib/util.c Mon Jun 3 21:11:11 2002
+++ samba-2.2.5pre1/source/lib/util.c Wed Jun 12 15:30:29 2002
-@@ -1860,6 +1860,46 @@
+@@ -1862,6 +1862,46 @@
return fname;
}
@@ -180,9 +180,8 @@ diff -uNr samba-2.2.5pre1.orig/source/nsswitch/winbindd_idmap.c samba-2.2.5pre1/
DEBUG(0, ("winbindd_idmap_init: Unable to open idmap database\n"));
return False;
}
-diff -uNr samba-2.2.5pre1.orig/source/param/loadparm.c samba-2.2.5pre1/source/param/loadparm.c
---- samba-2.2.5pre1.orig/source/param/loadparm.c Thu May 30 23:13:00 2002
-+++ samba-2.2.5pre1/source/param/loadparm.c Wed Jun 12 15:30:29 2002
+--- samba-2.2.5/source/param/loadparm.c.orig Tue Jun 18 21:13:45 2002
++++ samba-2.2.5/source/param/loadparm.c Tue Jun 18 23:24:14 2002
@@ -107,6 +107,9 @@
char *szAddPrinterCommand;
char *szDeletePrinterCommand;
@@ -193,7 +192,7 @@ diff -uNr samba-2.2.5pre1.orig/source/param/loadparm.c samba-2.2.5pre1/source/pa
char *szLockDir;
char *szPidDir;
char *szRootdir;
-@@ -1025,8 +1028,13 @@
+@@ -1046,8 +1046,13 @@
{"config file", P_STRING, P_GLOBAL, &Globals.szConfigFile, NULL, NULL, FLAG_HIDE},
{"preload", P_STRING, P_GLOBAL, &Globals.szAutoServices, NULL, NULL, FLAG_DOS_STRING},
{"auto services", P_STRING, P_GLOBAL, &Globals.szAutoServices, NULL, NULL, FLAG_DOS_STRING},
@@ -210,7 +209,7 @@ diff -uNr samba-2.2.5pre1.orig/source/param/loadparm.c samba-2.2.5pre1/source/pa
diff -uNr samba-2.2.5pre1.orig/source/printing/nt_printing.c samba-2.2.5pre1/source/printing/nt_printing.c
--- samba-2.2.5pre1.orig/source/printing/nt_printing.c Thu Jun 6 08:15:02 2002
+++ samba-2.2.5pre1/source/printing/nt_printing.c Wed Jun 12 15:30:29 2002
-@@ -263,24 +263,24 @@
+@@ -262,24 +262,24 @@
if (tdb_drivers && tdb_printers && tdb_forms && local_pid == sys_getpid())
return True;
diff --git a/packaging/Debian/debian/patches/loadparm.patch b/packaging/Debian/debian/patches/loadparm.patch
index ccca48793fc..d8b7ab00c2f 100644
--- a/packaging/Debian/debian/patches/loadparm.patch
+++ b/packaging/Debian/debian/patches/loadparm.patch
@@ -1,7 +1,6 @@
-diff -uNr samba-2.2.5pre1.orig/source/param/loadparm.c samba-2.2.5pre1/source/param/loadparm.c
---- samba-2.2.5pre1.orig/source/param/loadparm.c Wed Jun 12 15:42:59 2002
-+++ samba-2.2.5pre1/source/param/loadparm.c Wed Jun 12 15:43:10 2002
-@@ -1128,26 +1128,26 @@
+--- samba-2.2.5/source/param/loadparm.c.orig Tue Jun 18 23:15:07 2002
++++ samba-2.2.5/source/param/loadparm.c Tue Jun 18 23:15:07 2002
+@@ -1149,26 +1149,26 @@
case PRINT_AIX:
case PRINT_LPRNT:
case PRINT_LPROS2:
@@ -38,7 +37,7 @@ diff -uNr samba-2.2.5pre1.orig/source/param/loadparm.c samba-2.2.5pre1/source/pa
break;
case PRINT_CUPS:
-@@ -1163,19 +1163,19 @@
+@@ -1184,19 +1184,19 @@
string_set(&Globals.szPrintcapname, "cups");
#else
string_set(&sDefault.szLpqcommand,
@@ -65,7 +64,7 @@ diff -uNr samba-2.2.5pre1.orig/source/param/loadparm.c samba-2.2.5pre1/source/pa
string_set(&Globals.szPrintcapname, "lpstat");
#endif /* HAVE_CUPS */
break;
-@@ -1492,7 +1492,10 @@
+@@ -1515,7 +1515,10 @@
else
StrnCpy(ret, s, len);
@@ -75,5 +74,5 @@ diff -uNr samba-2.2.5pre1.orig/source/param/loadparm.c samba-2.2.5pre1/source/pa
+ StrnCpy(ret, s, len);
+ }
- standard_sub_basic(ret);
+ standard_sub_basic(ret, len + 100);
return (ret);
diff --git a/packaging/Debian/debian/patches/lpq_parse.c.patch b/packaging/Debian/debian/patches/lpq_parse.c.patch
index 37c9dc557d7..5e8d0cc1f0e 100644
--- a/packaging/Debian/debian/patches/lpq_parse.c.patch
+++ b/packaging/Debian/debian/patches/lpq_parse.c.patch
@@ -1,6 +1,6 @@
---- samba-2.2.4/source/printing/lpq_parse.c.orig Wed May 1 23:14:51 2002
-+++ samba-2.2.4/source/printing/lpq_parse.c Thu May 2 00:18:30 2002
-@@ -263,6 +263,9 @@
+--- samba/source/printing/lpq_parse.c.orig 2002-07-24 09:22:49.000000000 -0400
++++ samba/source/printing/lpq_parse.c 2002-10-13 01:43:10.000000000 -0400
+@@ -265,6 +265,9 @@
buf->status = LPQ_PAUSED;
}
diff --git a/packaging/Debian/debian/patches/samba.patch b/packaging/Debian/debian/patches/samba.patch
index 8321307a782..e7dd4d8813e 100644
--- a/packaging/Debian/debian/patches/samba.patch
+++ b/packaging/Debian/debian/patches/samba.patch
@@ -133,9 +133,9 @@
become_daemon();
---- samba-2.2.4/source/smbd/service.c.orig Wed May 1 23:15:10 2002
-+++ samba-2.2.4/source/smbd/service.c Thu May 2 00:20:44 2002
-@@ -713,6 +713,14 @@
+--- samba/source/smbd/service.c.orig 2002-10-12 11:54:24.000000000 -0400
++++ samba/source/smbd/service.c 2002-10-13 01:43:10.000000000 -0400
+@@ -698,6 +698,14 @@
smbrun(cmd,NULL);
}
diff --git a/packaging/Debian/debian/patches/smbclient-xfer-speed.patch b/packaging/Debian/debian/patches/smbclient-xfer-speed.patch
index adfce3ab90b..bbadda33870 100644
--- a/packaging/Debian/debian/patches/smbclient-xfer-speed.patch
+++ b/packaging/Debian/debian/patches/smbclient-xfer-speed.patch
@@ -1,5 +1,5 @@
---- samba-2.2.4/source/client/client.c.orig Wed May 1 23:13:57 2002
-+++ samba-2.2.4/source/client/client.c Thu May 2 00:34:16 2002
+--- samba-2.2.2.cvs20020120/source/client/client.c.orig Wed Jan 23 23:32:44 2002
++++ samba-2.2.2.cvs20020120/source/client/client.c Wed Jan 23 23:33:50 2002
@@ -91,10 +91,10 @@
extern file_info def_finfo;
diff --git a/packaging/Debian/debian/patches/smbmount-nomtab.patch b/packaging/Debian/debian/patches/smbmount-nomtab.patch
index 233356bd9ff..1cc45b68187 100644
--- a/packaging/Debian/debian/patches/smbmount-nomtab.patch
+++ b/packaging/Debian/debian/patches/smbmount-nomtab.patch
@@ -1,6 +1,5 @@
-diff -uNr samba-2.2.5pre1.orig/source/client/smbmnt.c samba-2.2.5pre1/source/client/smbmnt.c
---- samba-2.2.5pre1.orig/source/client/smbmnt.c Wed Jun 12 15:50:00 2002
-+++ samba-2.2.5pre1/source/client/smbmnt.c Wed Jun 12 15:50:04 2002
+--- samba-2.2.3a/source/client/smbmnt.c.orig Tue Apr 2 09:58:18 2002
++++ samba-2.2.3a/source/client/smbmnt.c Tue Apr 2 09:58:24 2002
@@ -28,6 +28,7 @@
static uid_t mount_uid;
static gid_t mount_gid;
@@ -36,7 +35,7 @@ diff -uNr samba-2.2.5pre1.orig/source/client/smbmnt.c samba-2.2.5pre1/source/cli
case 'r':
mount_ro = 1;
break;
-@@ -274,36 +279,38 @@
+@@ -271,36 +276,38 @@
return -1;
}
@@ -102,9 +101,8 @@ diff -uNr samba-2.2.5pre1.orig/source/client/smbmnt.c samba-2.2.5pre1/source/cli
return 0;
}
-diff -uNr samba-2.2.5pre1.orig/source/client/smbmount.c samba-2.2.5pre1/source/client/smbmount.c
---- samba-2.2.5pre1.orig/source/client/smbmount.c Wed Jun 12 15:46:02 2002
-+++ samba-2.2.5pre1/source/client/smbmount.c Wed Jun 12 15:50:04 2002
+--- samba/source/client/smbmount.c.orig 2002-10-13 01:34:58.000000000 -0400
++++ samba/source/client/smbmount.c 2002-10-13 01:34:59.000000000 -0400
@@ -50,6 +50,7 @@
static int mount_ro;
static unsigned mount_fmask;
diff --git a/packaging/Debian/debian/rules b/packaging/Debian/debian/rules
index db04766b9b7..d844a902ca2 100755
--- a/packaging/Debian/debian/rules
+++ b/packaging/Debian/debian/rules
@@ -4,6 +4,7 @@
# solve build problems) introduced in Samba 2.2.1a-5. These
# modification were made by Steve Langasek <vorlon@netexpress.net>.
#
+# $Id: rules,v 1.2.2.6 2002/10/15 21:36:46 jerry Exp $
#
# Uncomment this to turn on verbose mode.
@@ -75,8 +76,7 @@ configure-stamp:
--with-pam_smbpass \
--with-libsmbclient \
--with-winbind \
- --with-msdfs \
- --with-automount)
+ --with-msdfs)
touch configure-stamp
@@ -178,7 +178,7 @@ install: build
cp debian/smb.conf $(DESTDIR)/usr/share/samba/
cp debian/samba.pamd $(DESTDIR)/etc/pam.d/samba
- # This is to comply with policy (the symlink that ldconfig would
+ # This is to comply with policy (the symlink that ldconfig would
# produce must exist in the package).
/sbin/ldconfig -n $(DESTDIR)/usr/lib/
diff --git a/packaging/Debian/debian/samba-common.postinst b/packaging/Debian/debian/samba-common.postinst
index 54b5679932e..261684d61fb 100644
--- a/packaging/Debian/debian/samba-common.postinst
+++ b/packaging/Debian/debian/samba-common.postinst
@@ -1,18 +1,19 @@
#!/bin/sh
#
+# $Id: samba-common.postinst,v 1.1.4.4 2002/10/15 21:36:46 jerry Exp $
#
set -e
+# Do debconf stuff here
+. /usr/share/debconf/confmodule
+
# We need a default smb.conf file. If one doesn't exist we put in place
# one that has some basic defaults.
if [ ! -e /etc/samba/smb.conf ]; then
cp -a /usr/share/samba/smb.conf /etc/samba/
fi
-# Do debconf stuff here
-. /usr/share/debconf/confmodule
-
# ------------------------- Debconf questions start ---------------------
# Is the user configuring with debconf, or he/she prefers swat/manual
diff --git a/packaging/Debian/debian/samba-common.postrm b/packaging/Debian/debian/samba-common.postrm
index 8a4b6d3d55e..b5451ee65a2 100644
--- a/packaging/Debian/debian/samba-common.postrm
+++ b/packaging/Debian/debian/samba-common.postrm
@@ -1,5 +1,6 @@
#!/bin/sh
#
+# $Id: samba-common.postrm,v 1.2.2.6 2002/10/15 21:36:46 jerry Exp $
#
if [ "$1" = purge ]; then
diff --git a/packaging/Debian/debian/samba.init b/packaging/Debian/debian/samba.init
index 00b8dcbb100..b05abae866e 100644
--- a/packaging/Debian/debian/samba.init
+++ b/packaging/Debian/debian/samba.init
@@ -2,6 +2,7 @@
#
# Start/stops the Samba daemons (nmbd and smbd).
#
+# $Id: samba.init,v 1.2.2.6 2002/10/15 21:36:46 jerry Exp $
#
# Defaults
@@ -18,18 +19,14 @@ unset TMPDIR
# If Samba is running from inetd then there is nothing to do
if [ "$RUN_MODE" = "inetd" ]; then
- # INIT_VERSION is defined for scripts than run directly from init...
- if [ "$INIT_VERSION" = "" ]; then
- cat <<EOF
-
-Warning: Samba is set to start from inetd; this script has no effect.
-Run "dpkg-reconfigure samba" if you want Samba to be started and stopped
-from this script. If you want to continue running Samba from inetd, you
-should use "killall nmbd smbd" to restart the service, or update-inetd
-to disable/reenable it.
-
-EOF
- fi
+ # Commented out to close bug #26884 (startup message is rather long). I
+ # have yet to think how to let the user know that if he/she is running
+ # Samba from inetd, he can't just "/etc/init.d/samba stop" to stop
+ # the Samba daemons.
+# echo "Warning: Samba is not running as daemons. Daemons not restarted/stopped."
+# echo "Daemons will start automatically by inetd (if you wanted to start Samba)."
+# echo "If you want to stop Samba, get the PID's of all nmbd and smbd processes"
+# echo "and send them a SIGTERM signal but keep in mind that inetd could restart them."
exit 0
fi
@@ -49,30 +46,15 @@ case "$1" in
echo "."
;;
stop)
- echo -n "Stopping Samba daemons: "
+ echo -n "Stopping Samba daemons:"
+ echo -n " nmbd"
start-stop-daemon --stop --quiet --pidfile $NMBDPID
- # Wait a little and remove stale PID file
- sleep 1
- if [ -f $NMBDPID ] && ! ps h `cat $NMBDPID` > /dev/null
- then
- # Stale PID file (nmbd was succesfully stopped),
- # remove it (should be removed by nmbd itself IMHO.)
- rm -f $NMBDPID
- fi
- echo -n "nmbd "
+ echo -n " smbd"
start-stop-daemon --stop --quiet --pidfile $SMBDPID
- # Wait a little and remove stale PID file
- sleep 1
- if [ -f $SMBDPID ] && ! ps h `cat $SMBDPID` > /dev/null
- then
- # Stale PID file (nmbd was succesfully stopped),
- # remove it (should be removed by smbd itself IMHO.)
- rm -f $SMBDPID
- fi
- echo "smbd."
+ echo "."
;;
reload)
echo -n "Reloading /etc/samba/smb.conf (smbd only)"
@@ -81,9 +63,19 @@ case "$1" in
echo "."
;;
restart|force-reload)
- $0 stop
- sleep 1
- $0 start
+ echo -n "Restarting Samba daemons:"
+
+ echo -n " nmbd"
+ start-stop-daemon --stop --quiet --pidfile $NMBDPID
+ sleep 2
+ start-stop-daemon --start --quiet --exec /usr/sbin/nmbd -- -D
+
+ echo -n " smbd"
+ start-stop-daemon --stop --quiet --pidfile $SMBDPID
+ sleep 2
+ start-stop-daemon --start --quiet --exec /usr/sbin/smbd -- -D
+
+ echo "."
;;
*)
echo "Usage: /etc/init.d/samba {start|stop|reload|restart|force-reload}"