obnox/samba/samba-obnox.git
8 years agoctdb-scripts: Factor out possible creation of rt_tables file
Martin Schwenke [Mon, 17 Aug 2015 03:39:10 +0000 (13:39 +1000)]
ctdb-scripts: Factor out possible creation of rt_tables file

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: Move remaining state files into CTDB_SCRIPT_VARDIR
Martin Schwenke [Thu, 13 Aug 2015 05:57:52 +0000 (15:57 +1000)]
ctdb-scripts: Move remaining state files into CTDB_SCRIPT_VARDIR

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: New internal variable CTDB_SCRIPT_VARDIR
Martin Schwenke [Thu, 13 Aug 2015 05:54:20 +0000 (15:54 +1000)]
ctdb-scripts: New internal variable CTDB_SCRIPT_VARDIR

Clearly identifies where all state files from scripts should go and
allows that location to be easily changed.  This patch should not
change any behaviour (outside of eventscript unit tests, where a
clearer location is now used).

CTDB_VARDIR should no longer be overridden.  Continue to set
CTDB_DBDIR and similar to override database location in unit tests.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: Properly set CTDB_VARDIR in scripts at install time
Martin Schwenke [Thu, 13 Aug 2015 05:17:51 +0000 (15:17 +1000)]
ctdb-scripts: Properly set CTDB_VARDIR in scripts at install time

Have wscript do path substitution.

No need to export this and CTDB_ETCDIR here, but test scripts will
still need to do so.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-build: Add missing manual pages to pre-generate list for tarball
Martin Schwenke [Fri, 21 Aug 2015 11:19:55 +0000 (21:19 +1000)]
ctdb-build: Add missing manual pages to pre-generate list for tarball

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-docs: Update "ctdb reloadnodes" documentation
Martin Schwenke [Fri, 21 Aug 2015 06:07:21 +0000 (16:07 +1000)]
ctdb-docs: Update "ctdb reloadnodes" documentation

Format instructions for adding/deleting nodes with appropriate XML and
simplify wording.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: Drop internal file-level variables referencing $CTDB_VARDIR
Martin Schwenke [Mon, 10 Aug 2015 06:11:18 +0000 (16:11 +1000)]
ctdb-scripts: Drop internal file-level variables referencing $CTDB_VARDIR

Using $CTDB_VARDIR at file scope is dangerous because it doesn't
respect the configuration.  Uses of these variables are simple so just
drop the variables and use $CTDB_VARDIR inside functions where it is
safe.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: Drop file removal involving $ctdb_managed_dir
Martin Schwenke [Mon, 10 Aug 2015 06:33:42 +0000 (16:33 +1000)]
ctdb-scripts: Drop file removal involving $ctdb_managed_dir

This directory has been under $CTDB_VARDIR for a long time, so is
already removed.  The command is also potentially dangerous if
$ctdb_managed_dir is not set.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: Drop functions ctdb_checkstatus() and ctdb_setstatus()
Martin Schwenke [Mon, 10 Aug 2015 06:03:05 +0000 (16:03 +1000)]
ctdb-scripts: Drop functions ctdb_checkstatus() and ctdb_setstatus()

They're not used outside of ctdb_standard_event_helper().

As a consequence, make ctdb_standard_event_helper() do nothing.  It is
harder to remove because it is used in many places, perhaps by
external eventscripts where it has been copied from existing scripts.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: Drop 62.cnfs eventscript
Martin Schwenke [Mon, 10 Aug 2015 05:34:29 +0000 (15:34 +1000)]
ctdb-scripts: Drop 62.cnfs eventscript

To get a similar effect just do something like this:

  mmaddcallback ctdb-disable-on-quorumLoss \
    --command /usr/bin/ctdb \
    --event quorumLoss --parms "disable"

  mmaddcallback ctdb-enable-on-quorumReached \
    --command /usr/bin/ctdb \
    --event quorumReached --parms "enable"

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoctdb-scripts: New internal variable CTDB_NFS_CALLOUT_STATE_DIR
Martin Schwenke [Tue, 1 Sep 2015 23:27:58 +0000 (09:27 +1000)]
ctdb-scripts: New internal variable CTDB_NFS_CALLOUT_STATE_DIR

60.nfs sets this to a directory where the NFS callout can store state.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Mon Sep 14 08:36:34 CEST 2015 on sn-devel-104

8 years agos3: dfs: Fix a crash when the dfs targets are disabled.
Har Gagan Sahai [Thu, 10 Sep 2015 10:34:27 +0000 (16:04 +0530)]
s3: dfs: Fix a crash when the dfs targets are disabled.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11509

Signed-off-by: Har Gagan Sahai <SHarGagan@novell.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ira Cooper <ira@wakeful.net>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Sep 11 06:39:19 CEST 2015 on sn-devel-104

8 years agobuild: use as-needed linker flag also on OpenBSD
Björn Jacke [Thu, 10 Sep 2015 19:31:03 +0000 (21:31 +0200)]
build: use as-needed linker flag also on OpenBSD

OpenBSD is unusable with binaries with many superfluous libs linked in.
samba-tool start times of 250 seconds without as-needed vs. 1.4 seconds with
as-needed.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11355

Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Ralph Böhme <rb@sernet.de>
Autobuild-User(master): Björn Jacke <bj@sernet.de>
Autobuild-Date(master): Fri Sep 11 03:37:17 CEST 2015 on sn-devel-104

8 years agonss_winbind: fix hang on Solaris on big groups
Björn Jacke [Thu, 10 Sep 2015 12:35:32 +0000 (14:35 +0200)]
nss_winbind: fix hang on Solaris on big groups

The problem with large groups on Solaris in the the NSS winbind module is
Solaris wants the return value to be NSS_UNAVAIL if the buffer given is too
small for getgrnam_r.  The current code return NSS_TRYAGAIN which causes
Solaris/Illumos to loop without trying to resize the buffer.

Thanks to  Nathan Huff <nhuff@acm.org> for finding this out.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10365

Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Ralph Böhme <rb@sernet.de>
8 years agonss_wins: add module for FreeBSD
Björn Jacke [Thu, 10 Sep 2015 09:27:42 +0000 (11:27 +0200)]
nss_wins: add module for FreeBSD

Thanks to Timur Bakeyev <timur@FreeBSD.org> for the patch.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11493

Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Ralph Böhme <rb@sernet.de>
8 years agosmbXsrv_session: factor smbXsrv_session_add_channel() out of smbXsrv_session_create()
Stefan Metzmacher [Wed, 25 Jun 2014 14:09:04 +0000 (16:09 +0200)]
smbXsrv_session: factor smbXsrv_session_add_channel() out of smbXsrv_session_create()

This allows to create more than one channel.

Pair-Programmed-With: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Sep 10 21:33:47 CEST 2015 on sn-devel-104

8 years agos3:smb2_sesssetup: let smbd_smb2_reauth_generic_return() cope with channels
Stefan Metzmacher [Wed, 29 Jul 2015 15:44:37 +0000 (17:44 +0200)]
s3:smb2_sesssetup: let smbd_smb2_reauth_generic_return() cope with channels

Pair-Programmed-With: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
8 years agos3:smb2_sesssetup: let smbd_smb2_auth_generic_return() cope with channels
Michael Adam [Wed, 29 Jul 2015 15:42:55 +0000 (17:42 +0200)]
s3:smb2_sesssetup: let smbd_smb2_auth_generic_return() cope with channels

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
8 years agos3:smb2_sesssetup: change talloc hierarchy in smbd_smb2_session_setup_gensec_done
Michael Adam [Wed, 29 Jul 2015 15:07:29 +0000 (17:07 +0200)]
s3:smb2_sesssetup: change talloc hierarchy in smbd_smb2_session_setup_gensec_done

Only put session_info to the session->global context if we use it.

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
8 years agoreplace: Fix check for gettimeofday()
Andreas Schneider [Wed, 9 Sep 2015 11:47:42 +0000 (13:47 +0200)]
replace: Fix check for gettimeofday()

The check does not include <sys/time.h> the test might fail with a
implicit function declaration error.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Sep 10 00:36:16 CEST 2015 on sn-devel-104

8 years agonet: reformat usage text for 'net ads join'
Michael Adam [Wed, 9 Sep 2015 06:58:43 +0000 (08:58 +0200)]
net: reformat usage text for 'net ads join'

Make the items nicely aligned again and do not exceed 80 columns.
A few typos are fixed along the way.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
8 years agodocs: mention new --no-dns-updates parameter in manpage of net.
Michael Adam [Wed, 9 Sep 2015 06:40:31 +0000 (08:40 +0200)]
docs: mention new --no-dns-updates parameter in manpage of net.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
8 years agonet: add option --no-dns-updates for net ads join
Michael Adam [Wed, 9 Sep 2015 06:28:43 +0000 (08:28 +0200)]
net: add option --no-dns-updates for net ads join

If called with this option, 'net ads join' will not attempt
to perform dns updates.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
8 years agolibsmb: Fix CID 1034606 Incorrect pointer comparison
Anoop C S [Wed, 9 Sep 2015 06:37:21 +0000 (06:37 +0000)]
libsmb: Fix CID 1034606 Incorrect pointer comparison

Signed-off-by: Anoop C S <anoopcs@redhat.com>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Wed Sep  9 21:33:49 CEST 2015 on sn-devel-104

8 years agolibsmb: Fix CID 1034605 Incorrect pointer comparison
Anoop C S [Wed, 9 Sep 2015 06:35:15 +0000 (06:35 +0000)]
libsmb: Fix CID 1034605 Incorrect pointer comparison

Signed-off-by: Anoop C S <anoopcs@redhat.com>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agowinbindd: Fix CID 1273310 Remove structurally dead code
Anoop C S [Tue, 8 Sep 2015 08:21:47 +0000 (08:21 +0000)]
winbindd: Fix CID 1273310 Remove structurally dead code

Signed-off-by: Anoop C S <anoopcs@redhat.com>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agobuild: line-break deps for 'param' subsystem
Michael Adam [Tue, 10 Jun 2014 14:48:40 +0000 (16:48 +0200)]
build: line-break deps for 'param' subsystem

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Wed Sep  9 13:12:43 CEST 2015 on sn-devel-104

8 years agobuild: fix quotation of deps for 'param' subsystem.
Michael Adam [Fri, 3 Jul 2015 10:12:44 +0000 (12:12 +0200)]
build: fix quotation of deps for 'param' subsystem.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agoctdb-server: fix a possible fd leak in ctdb_tcp_listen_automatic()
Michael Adam [Tue, 8 Sep 2015 08:01:31 +0000 (10:01 +0200)]
ctdb-server: fix a possible fd leak in ctdb_tcp_listen_automatic()

sockets are created in a loop until an unused address is found.
But the unused socket fds were not closed.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agoctdb: improve a misleading help text.
Michael Adam [Mon, 7 Sep 2015 16:09:44 +0000 (18:09 +0200)]
ctdb: improve a misleading help text.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agoctdb-doc: remove description of removed --syslog option from ctdbd manpage
Michael Adam [Tue, 8 Sep 2015 08:08:20 +0000 (10:08 +0200)]
ctdb-doc: remove description of removed --syslog option from ctdbd manpage

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agopam_winbind: Fix a segfault if initialization fails
Andreas Schneider [Tue, 8 Sep 2015 14:48:08 +0000 (16:48 +0200)]
pam_winbind: Fix a segfault if initialization fails

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11502

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Tue Sep  8 21:39:21 CEST 2015 on sn-devel-104

8 years agoswrap: Bump version to 1.1.4
Andreas Schneider [Tue, 25 Aug 2015 15:22:09 +0000 (17:22 +0200)]
swrap: Bump version to 1.1.4

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Tue Sep  8 16:49:23 CEST 2015 on sn-devel-104

8 years agoswrap: Call dlclose() in the destructor
Andreas Schneider [Tue, 25 Aug 2015 15:21:33 +0000 (17:21 +0200)]
swrap: Call dlclose() in the destructor

Signed-off-by: Andreas Schneider <asn@samba.org>
8 years agoswrap: Fix signed comparsion warnings
Andreas Schneider [Tue, 25 Aug 2015 15:21:05 +0000 (17:21 +0200)]
swrap: Fix signed comparsion warnings

Signed-off-by: Andreas Schneider <asn@samba.org>
8 years agoswrap: Add environment variable to specify mtu size
Andreas Schneider [Tue, 25 Aug 2015 15:20:20 +0000 (17:20 +0200)]
swrap: Add environment variable to specify mtu size

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agoswrap: Fix TCP support with sendmsg/recvmsg
Andreas Schneider [Tue, 25 Aug 2015 15:19:43 +0000 (17:19 +0200)]
swrap: Fix TCP support with sendmsg/recvmsg

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agoswrap: Correctly update the msg_name in recvmsg()
Andreas Schneider [Tue, 25 Aug 2015 15:19:02 +0000 (17:19 +0200)]
swrap: Correctly update the msg_name in recvmsg()

This has been found while debugging nsupdate.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agorwrap: Bump version to 1.1.3
Andreas Schneider [Tue, 25 Aug 2015 09:45:20 +0000 (11:45 +0200)]
rwrap: Bump version to 1.1.3

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agorwrap: Fix strict aliasing warnings for symbol binding
Andreas Schneider [Tue, 25 Aug 2015 09:44:54 +0000 (11:44 +0200)]
rwrap: Fix strict aliasing warnings for symbol binding

Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agoFind the correct symbol when res_* is a define to __res_*
Andrew Bartlett [Tue, 25 Aug 2015 09:44:21 +0000 (11:44 +0200)]
Find the correct symbol when res_* is a define to __res_*

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agofruit: Fix CID 1323186 Dereference before null check
Volker Lendecke [Tue, 8 Sep 2015 06:18:02 +0000 (08:18 +0200)]
fruit: Fix CID 1323186 Dereference before null check

In all other "goto fail;" paths we had already dereferenced fsp,
so the if-statement checking for fsp!=NULL was unnecessary. This
fix gives us an additional error message in case check_aapl fails.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Tue Sep  8 13:47:01 CEST 2015 on sn-devel-104

8 years agodsdb: Fix a confusing parameter
Volker Lendecke [Tue, 8 Sep 2015 05:47:55 +0000 (07:47 +0200)]
dsdb: Fix a confusing parameter

LDB_SCOPE_BASE is 0, so this works, but the corresponding parameter
is "struct ldb_control **controls", so I'd say NULL is more appropriate
here. Fixes a warning I just saw pass by.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agosamdb: Fix CID 1034736 Dereference after null check
Volker Lendecke [Tue, 8 Sep 2015 05:46:35 +0000 (07:46 +0200)]
samdb: Fix CID 1034736 Dereference after null check

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agoconfigure: Fix aio_suspend detection
Timur Bakeyev [Fri, 4 Sep 2015 13:03:24 +0000 (15:03 +0200)]
configure: Fix aio_suspend detection

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11494

Signed-off-by: Timur Bakeyev <timur@FreeBSD.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agolibsmbclient: Fix 32-bit problems
Volker Lendecke [Fri, 4 Sep 2015 14:40:25 +0000 (16:40 +0200)]
libsmbclient: Fix 32-bit problems

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Mon Sep  7 15:13:08 CEST 2015 on sn-devel-104

8 years agoctdb-tools: Add dbstatistics to ctdb_diagnostics
Martin Schwenke [Sun, 16 Aug 2015 03:26:21 +0000 (13:26 +1000)]
ctdb-tools: Add dbstatistics to ctdb_diagnostics

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Mon Sep  7 10:00:54 CEST 2015 on sn-devel-104

8 years agoctdb-daemon: Drop struct ctdb_control_killtcp
Martin Schwenke [Mon, 23 Mar 2015 05:10:51 +0000 (16:10 +1100)]
ctdb-daemon: Drop struct ctdb_control_killtcp

Just use ctdb_tcp_connection.  It is the same.  There are no external
users.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Volker Lendecke <vl@samba.org>
8 years agovfs_gpfs: Avoid calling gpfs_is_offline on every i/o
Volker Lendecke [Wed, 2 Sep 2015 11:20:08 +0000 (13:20 +0200)]
vfs_gpfs: Avoid calling gpfs_is_offline on every i/o

Asks gpfs as long as a file is offline. Once it was reported online once,
we'll not ask anymore.  This assumes that while we have a file open it
won't be migrated away. This might not *always* be true, but probably
close enough. And as long as we don't have a proper notification mechanism
and as long as polling is too expensive, this seems like a good strategy.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
Autobuild-User(master): Christof Schmitt <cs@samba.org>
Autobuild-Date(master): Sat Sep  5 01:50:09 CEST 2015 on sn-devel-104

8 years agovfs_gpfs: Introduce vfs_gpfs_fsp_is_offline
Volker Lendecke [Thu, 3 Sep 2015 10:10:35 +0000 (12:10 +0200)]
vfs_gpfs: Introduce vfs_gpfs_fsp_is_offline

This consolidates a few common calls

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
8 years agowinbind: Don't delete an existing krb5 ticket on cached logon.
Jeremy Allison [Thu, 3 Sep 2015 00:12:33 +0000 (17:12 -0700)]
winbind: Don't delete an existing krb5 ticket on cached logon.

Cached logon doesn't mean the ticket is bad, wait until we go
online again to determine that.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11198

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Sep  4 01:35:16 CEST 2015 on sn-devel-104

8 years agoctdb: Fix a 32-bit problem
Volker Lendecke [Thu, 3 Sep 2015 14:25:02 +0000 (16:25 +0200)]
ctdb: Fix a 32-bit problem

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Thu Sep  3 22:12:02 CEST 2015 on sn-devel-104

8 years agoFix memory leak in dns resolution during spnego authentication using kerberos.
Har Gagan Sahai [Wed, 2 Sep 2015 17:54:24 +0000 (10:54 -0700)]
Fix memory leak in dns resolution during spnego authentication using kerberos.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11471

Signed-off-by: Har Gagan Sahai <SHarGagan@novell.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Thu Sep  3 19:11:22 CEST 2015 on sn-devel-104

8 years agotls: increase Diffie-Hellman group size to 2048 bits
Björn Jacke [Wed, 2 Sep 2015 10:37:12 +0000 (12:37 +0200)]
tls: increase Diffie-Hellman group size to 2048 bits

1024 bits is already the minimum accepted size of current TLS libraries. 2048
is recommended for servers, see https://weakdh.org/

Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu Sep  3 03:47:48 CEST 2015 on sn-devel-104

8 years agodoc: fix description of tls dh params file parameter
Björn Jacke [Wed, 2 Sep 2015 10:37:11 +0000 (12:37 +0200)]
doc: fix description of tls dh params file parameter

Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agos4:torture:vfs_fruit: created empty resourceforks
Ralph Boehme [Fri, 7 Aug 2015 13:48:33 +0000 (15:48 +0200)]
s4:torture:vfs_fruit: created empty resourceforks

Check for opens and creates, created empty resourceforks result in
ENOENT in subsequent opens.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11467

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Sep  2 06:50:16 CEST 2015 on sn-devel-104

8 years agos4:torture:vfs_fruit: add a resource fork truncation test
Ralph Boehme [Thu, 6 Aug 2015 09:32:29 +0000 (11:32 +0200)]
s4:torture:vfs_fruit: add a resource fork truncation test

Truncating a resource fork to 0 bytes should make it inaccessible for
subsequent creates and return NT_STATUS_OBJECT_NAME_NOT_FOUND.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11467

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
8 years agovfs_fruit: delete ._ file when deleting the basefile
Ralph Boehme [Tue, 25 Aug 2015 15:06:52 +0000 (17:06 +0200)]
vfs_fruit: delete ._ file when deleting the basefile

0 byte resource fork streams are not listed by vfs_streaminfo, as a
result stream cleanup/deletion of file deletion doesn't remove the
resourcefork stream.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11467

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
8 years agovfs_fruit: split and simplify fruit_ftruncate
Ralph Boehme [Wed, 12 Aug 2015 05:34:53 +0000 (07:34 +0200)]
vfs_fruit: split and simplify fruit_ftruncate

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11467

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
8 years agovfs_fruit: handling of empty resource fork
Ralph Boehme [Sat, 8 Aug 2015 18:21:39 +0000 (20:21 +0200)]
vfs_fruit: handling of empty resource fork

Opening the resource fork stream with O_CREAT mustn't create a visible
node in the filesystem, only create a file handle. As long as the
creator didn't write into the stream, other openers withour O_CREAT
MUST get an ENOENT error. This is way OS X SMB server implements it.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11467

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
8 years agobuild:wafsamba: Use the Waf 1.8 API get_tgen_by_name instead of name_to_obj
Thomas Nagy [Fri, 26 Jun 2015 20:32:43 +0000 (22:32 +0200)]
build:wafsamba: Use the Waf 1.8 API get_tgen_by_name instead of name_to_obj

Signed-off-by: Thomas Nagy <tnagy@waf.io>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed Sep  2 03:49:51 CEST 2015 on sn-devel-104

8 years agobuild:wafsamba: Close file handles in the build scripts too
Thomas Nagy [Fri, 26 Jun 2015 18:48:43 +0000 (20:48 +0200)]
build:wafsamba: Close file handles in the build scripts too

Signed-off-by: Thomas Nagy <tnagy@waf.io>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agothird_party:waf: fix a mis-merge - Utils.check_dir issue
Thomas Nagy [Fri, 26 Jun 2015 18:17:06 +0000 (20:17 +0200)]
third_party:waf: fix a mis-merge - Utils.check_dir issue

Signed-off-by: Thomas Nagy <tnagy@waf.io>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agothird_party:waf: Backport parts of the waf 1.8 API
Thomas Nagy [Fri, 26 Jun 2015 18:13:09 +0000 (20:13 +0200)]
third_party:waf: Backport parts of the waf 1.8 API

This modifies our waf 1.5 wafadmin copy to resemble the waf 1.8
waflib API.  It is a preparation to change to waf 1.8, decoupling
this change from changes in wafsamba.

Signed-off-by: Thomas Nagy <tnagy@waf.io>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agosamr4: Use <SID=%s> in GetGroupsForUser
Volker Lendecke [Tue, 1 Sep 2015 06:41:04 +0000 (08:41 +0200)]
samr4: Use <SID=%s> in GetGroupsForUser

This way we avoid quoting problems in user's DNs

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Sep  1 23:49:14 CEST 2015 on sn-devel-104

8 years agoRevert "winbind: Fix 100% loop"
Volker Lendecke [Tue, 1 Sep 2015 15:13:36 +0000 (17:13 +0200)]
Revert "winbind: Fix 100% loop"

This reverts commit e551cdb37d3e8cfb155bc33f9b162761c8d60889.

Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Tue Sep  1 20:47:50 CEST 2015 on sn-devel-104

8 years agopython/tests: Add more assertions that we get back the value we expect
Andrew Bartlett [Tue, 1 Sep 2015 03:00:30 +0000 (15:00 +1200)]
python/tests: Add more assertions that we get back the value we expect

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Sep  1 17:00:53 CEST 2015 on sn-devel-104

8 years agopython/tests: Add tests for 64 bit signed integers
Andrew Bartlett [Tue, 1 Sep 2015 02:58:20 +0000 (14:58 +1200)]
python/tests: Add tests for 64 bit signed integers

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agopidl/python: also add a ndr_PyLong_FromLongLong() for symnetric reasons
Stefan Metzmacher [Tue, 1 Sep 2015 08:30:49 +0000 (10:30 +0200)]
pidl/python: also add a ndr_PyLong_FromLongLong() for symnetric reasons

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agopidl/python: Provide static inline helper function ndr_PyLong_FromUnsignedLongLong
Andrew Bartlett [Tue, 1 Sep 2015 02:33:35 +0000 (14:33 +1200)]
pidl/python: Provide static inline helper function ndr_PyLong_FromUnsignedLongLong

This should isolate any coverity warnings on 64-bit platforms
(where LONG_MAX is larger than any possible 32 bit value) to
a single spot, or possibly eliminate it.

This is needed for the unsigned 64 bit case, and on 32 bit
systems, as PyInt_FromLong is limited to a signed "long" int.

The compiler should be able to eliminate many of these calls
with the embedded type knowlege.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agopidl/python: Calculate maximum integer values using a lookup table
Andrew Bartlett [Thu, 27 Aug 2015 23:46:56 +0000 (11:46 +1200)]
pidl/python: Calculate maximum integer values using a lookup table

This avoids a << of 64 bits in the unused end of the conditional expression.

This was flagged by Coverity and the fix was suggested by metze.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429

Andrew Bartlett

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agospoolss: handle SetPrinter for info level 4
Garming Sam [Mon, 17 Nov 2014 23:41:30 +0000 (12:41 +1300)]
spoolss: handle SetPrinter for info level 4

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10770

Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Sep  1 03:33:13 CEST 2015 on sn-devel-104

8 years agoldb:wscript: make it possible to build samba with a system ldb again
Stefan Metzmacher [Thu, 27 Aug 2015 09:14:51 +0000 (11:14 +0200)]
ldb:wscript: make it possible to build samba with a system ldb again

This fixes a regression in commit fcf4a891945b22dc6eccdc71fd441f1a879f556a.

If we check for 'ldb' later the 'pyldb-util' can't depend on the 'ldb' check.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11458

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Aug 31 18:53:16 CEST 2015 on sn-devel-104

8 years agoselftest: add a check for disabled change notify
Ralph Boehme [Wed, 12 Aug 2015 09:06:15 +0000 (11:06 +0200)]
selftest: add a check for disabled change notify

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11444

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Mon Aug 31 15:50:49 CEST 2015 on sn-devel-104

8 years agoselftest: add change notify = no to simpleserver env
Ralph Boehme [Wed, 12 Aug 2015 09:35:27 +0000 (11:35 +0200)]
selftest: add change notify = no to simpleserver env

A subsequent patch will use this env in a torture test.

The aren't any existing tests that make use of change notify, so
disabling change notify in this test environment doesn't impact existing
tests.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11444

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonotify: check for valid notify_ctx in notify_remove
Ralph Boehme [Tue, 11 Aug 2015 14:49:46 +0000 (16:49 +0200)]
notify: check for valid notify_ctx in notify_remove

notify_ctx will be NULL when "change notify = no" is set in smb.conf.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11444

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agoweb_server: Fix server not to segfault on startup
Andrew Bartlett [Sun, 30 Aug 2015 23:08:45 +0000 (11:08 +1200)]
web_server: Fix server not to segfault on startup

Pair-programmed-with: Garming Sam <garming@catalyst.net.nz>
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon Aug 31 04:11:55 CEST 2015 on sn-devel-104

8 years agoweb_server: Use talloc_get_type_abort()
Andrew Bartlett [Sun, 30 Aug 2015 22:59:58 +0000 (10:59 +1200)]
web_server: Use talloc_get_type_abort()

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Pair-programmed-with: Garming Sam <garming@catalyst.net.nz>

8 years agolib/tls: Ensure SSLv3 is disabled in the web server by default
Andrew Bartlett [Sun, 30 Aug 2015 22:48:08 +0000 (10:48 +1200)]
lib/tls: Ensure SSLv3 is disabled in the web server by default

By calling gnutls_priority_set_direct() the behaviour should now match the LDAP server

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11076
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Pair-programmed-with: Garming Sam <garming@catalyst.net.nz>

8 years agolib/tls: Remove unused tls_init_client code
Andrew Bartlett [Sun, 30 Aug 2015 22:33:34 +0000 (10:33 +1200)]
lib/tls: Remove unused tls_init_client code

This is unused as the callers have now been migrated to tls_tstream

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11076
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Pair-programmed-with: Garming Sam <garming@catalyst.net.nz>

8 years agoctdb-scripts: Add default filesystem usage warnings
Martin Schwenke [Tue, 18 Aug 2015 05:22:23 +0000 (15:22 +1000)]
ctdb-scripts: Add default filesystem usage warnings

Always check filesystem usage for the database directories.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Sat Aug 29 20:08:48 CEST 2015 on sn-devel-104

8 years agoctdb-scripts: Add default system memory usage warnings
Martin Schwenke [Fri, 14 Aug 2015 07:08:45 +0000 (17:08 +1000)]
ctdb-scripts: Add default system memory usage warnings

CTDB should warn by default if too much system memory or swap is used.

The tests have also been tweaked.  In particular, the filesystem-only
tests need to initialise the memory information to avoid errors where
meminfo isn't set.

Document the defaults, warning against disabling them.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Enable system monitoring eventscript by default
Martin Schwenke [Thu, 6 Aug 2015 05:59:06 +0000 (15:59 +1000)]
ctdb-scripts: Enable system monitoring eventscript by default

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Throttle system resource monitoring warnings
Martin Schwenke [Wed, 5 Aug 2015 10:42:16 +0000 (20:42 +1000)]
ctdb-scripts: Throttle system resource monitoring warnings

They are only printed when the percentage usage changes.  This should
stop the logs from being filled with warnings.

Add a test for the throttling.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Don't shutdown CTDB when memory monitoring fails
Martin Schwenke [Mon, 3 Aug 2015 09:55:27 +0000 (19:55 +1000)]
ctdb-scripts: Don't shutdown CTDB when memory monitoring fails

Marking the node unhealthy should cause Samba processes to close,
possible freeing a stack of memory.  If not, then it is somebody
else's problem.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: New consistent system memory and swap monitoring
Martin Schwenke [Mon, 3 Aug 2015 07:22:08 +0000 (17:22 +1000)]
ctdb-scripts: New consistent system memory and swap monitoring

New variables CTDB_MONITOR_MEMORY_USAGE and CTDB_MONITOR_SWAP_USAGE.
Both take a pair of <warn_threshold>:<unhealthy_threshold> where each
theshold is specified as a percentage.

This adds a callout to check_thresholds() that is run when the
unhealthy threshold is reached.

Add some combination tests.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Factor out new function check_thresholds()
Martin Schwenke [Mon, 3 Aug 2015 06:20:40 +0000 (16:20 +1000)]
ctdb-scripts: Factor out new function check_thresholds()

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Memory monitoring uses thresholds expressed as percentages
Martin Schwenke [Mon, 3 Aug 2015 05:59:50 +0000 (15:59 +1000)]
ctdb-scripts: Memory monitoring uses thresholds expressed as percentages

CTDB_MONITOR_FREE_MEMORY and CTDB_MONITOR_FREE_MEMORY_WARN are now
percentages that specify thresholds of acceptable memory usage.

Memory/swap usage in tests also specified as percentages.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Use MemAvailable if it is in /proc/meminfo
Martin Schwenke [Fri, 24 Jul 2015 09:57:42 +0000 (19:57 +1000)]
ctdb-scripts: Use MemAvailable if it is in /proc/meminfo

Otherwise calculate, as before.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Only use /proc/meminfo for memory checks, not "free"
Martin Schwenke [Mon, 20 Jul 2015 10:50:56 +0000 (20:50 +1000)]
ctdb-scripts: Only use /proc/meminfo for memory checks, not "free"

No need to use 2 different sources of information for similar checks.
Also, output of free has been changed, whereas /proc/meminfo is a
kernel API, which will not change.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Move system memory checking to 05.system
Martin Schwenke [Mon, 20 Jul 2015 06:08:13 +0000 (16:08 +1000)]
ctdb-scripts: Move system memory checking to 05.system

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-tests: Remove unwanted trailing whitespace
Martin Schwenke [Thu, 20 Aug 2015 01:47:19 +0000 (11:47 +1000)]
ctdb-tests: Remove unwanted trailing whitespace

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-tests: Add tests for filesystem usage monitoring
Martin Schwenke [Fri, 17 Jul 2015 11:32:01 +0000 (21:32 +1000)]
ctdb-tests: Add tests for filesystem usage monitoring

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: New configuration variable CTDB_MONITOR_FILESYSTEM_USAGE
Martin Schwenke [Mon, 3 Aug 2015 04:56:40 +0000 (14:56 +1000)]
ctdb-scripts: New configuration variable CTDB_MONITOR_FILESYSTEM_USAGE

This allows both errors (i.e. unhealthy) and warnings for different
thresholds.  It replaces CTDB_CHECK_FS_USE.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Don't fail monitoring if sanity checks fail
Martin Schwenke [Fri, 24 Jul 2015 09:56:06 +0000 (19:56 +1000)]
ctdb-scripts: Don't fail monitoring if sanity checks fail

Just log some warnings.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Move filesystem monitoring into a function, clean it up
Martin Schwenke [Fri, 17 Jul 2015 10:04:44 +0000 (20:04 +1000)]
ctdb-scripts: Move filesystem monitoring into a function, clean it up

Drop obvious comments.  Use die() for less lines of code.  Use a case
statement to avoid forking unnecessary processes for each filesystem
being checked.  Drop parentheses around percentages in messages.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Rename 40.fs_use to 05.system
Martin Schwenke [Fri, 17 Jul 2015 01:59:56 +0000 (11:59 +1000)]
ctdb-scripts: Rename 40.fs_use to 05.system

Will put all the system monitoring in here, simplifying 00.ctdb.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agos3: add suport for SMB3_10 and SMB3_11 protocols in smbstatus
Ralph Wuerthner [Fri, 28 Aug 2015 12:42:32 +0000 (14:42 +0200)]
s3: add suport for SMB3_10 and SMB3_11 protocols in smbstatus

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11472

Signed-off-by: Ralph Wuerthner <ralph.wuerthner@de.ibm.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Aug 29 07:05:10 CEST 2015 on sn-devel-104

8 years agopython: Remove uuid module
Petr Viktorin [Tue, 14 Jul 2015 09:02:36 +0000 (11:02 +0200)]
python: Remove uuid module

The uuid module was only built for Python 2.4 and lower, which Samba
no longer supports.

Python 2.5+ includes uuid in its standard library.

Signed-off-by: Petr Viktorin <pviktori@redhat.com>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Sat Aug 29 04:03:49 CEST 2015 on sn-devel-104

8 years agowinbind: Fix 100% loop
Volker Lendecke [Fri, 28 Aug 2015 10:33:13 +0000 (12:33 +0200)]
winbind: Fix 100% loop

Thanks to "L.P.H. van Belle" <belle@bazuin.nl>
for help in reproducing the issue.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11038

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Aug 28 22:03:31 CEST 2015 on sn-devel-104