Andreas Schneider [Fri, 28 Feb 2014 14:46:01 +0000 (15:46 +0100)]
Revert "pidl: Install pidl files corrently."
This reverts commit
cee11cfa4544425099268cd32393169afb4bb107.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andreas Schneider [Fri, 28 Feb 2014 14:45:51 +0000 (15:45 +0100)]
Revert "waf: Add option to specify perl vendor dir."
This reverts commit
9b200555fec2e33da9521db388d1839375aa8d83.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andreas Schneider [Fri, 28 Feb 2014 14:45:35 +0000 (15:45 +0100)]
Revert "pidl: Make perl(Parse:Yapp:Driver) installation optional."
This reverts commit
f0030c619bcf22dbe9eed54b2c0dc9c61f564838.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Fri, 21 Feb 2014 22:43:17 +0000 (23:43 +0100)]
ctdb-vacuum: fix delete list counts in delete_marshall_traverse_first
when bumping skipped, decrement left, so the sum is correct
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Thu Mar 6 03:32:33 CET 2014 on sn-devel-104
Michael Adam [Wed, 19 Feb 2014 23:58:17 +0000 (00:58 +0100)]
ctdb-vacuum: fix possible cause for delelete_list processing counts left records > 0
We need to have left records == 0 at the end of the delete list processing.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Wed, 19 Feb 2014 23:32:08 +0000 (00:32 +0100)]
ctdb-vacuum: systematize counters into various structs
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Wed, 19 Feb 2014 23:29:47 +0000 (00:29 +0100)]
ctdb-vacuum: remove unused counter vdata->total
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sun, 16 Feb 2014 00:08:18 +0000 (01:08 +0100)]
ctdb-vacuum: make ctdb_process_delete_list() void
The overall return code was not really used anyways.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sat, 15 Feb 2014 23:37:43 +0000 (00:37 +0100)]
ctdb-vacuum: make ctdb_process_vacuum_fetch_lists() void.
This constantly returns 0 anyways.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sat, 15 Feb 2014 23:35:34 +0000 (00:35 +0100)]
ctdb-vacuum: make ctdb_vacuum_traverse_db() void.
Failure in traversal of the DB should not
prevent further processing.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sat, 15 Feb 2014 23:26:00 +0000 (00:26 +0100)]
ctdb-vacuum: don't stop in process_vacuum_fetch_lists when sending to one node fails.
We should try to continue vacuuming as much as possible.
Failure to send records to one lmaster doesn't mean the
others will fail too.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sat, 15 Feb 2014 17:06:09 +0000 (18:06 +0100)]
ctdb-vacuum: catch and log errors to traverse the delete list in ctdb_process_delete_list()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sat, 15 Feb 2014 16:59:22 +0000 (17:59 +0100)]
ctdb-vacuum: catch and log error of traverse in ctdb_process_delete_queue()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sat, 15 Feb 2014 12:03:51 +0000 (13:03 +0100)]
ctdb-vacuum: use tdb_parse_record instead of tdb_fetch in delete_marshall_traverse_first()
Spare malloc and free.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Sat, 15 Feb 2014 12:01:33 +0000 (13:01 +0100)]
ctdb-vacuum: simplify delete_marshall_traverse_first: use tdb_null
we know anyways the record to store is empty at this point.
So skip pointer calculations.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 21:05:21 +0000 (22:05 +0100)]
ctdb-vacuum: remove VacuumLimit criterion for triggering a repack
With the new vacuuming, we consider it an error if there are
records left for deletion after processing the various lists.
All records that can be deleted should have been deleted by
tdb_delete calls.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Wed, 12 Feb 2014 16:41:28 +0000 (17:41 +0100)]
ctdb-vacuum: treat value 0 of tunable VacuumLimit as turning off repacking
I.e. no number of records found to delete will trigger the
repacking.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 21:02:41 +0000 (22:02 +0100)]
ctdb-vacuum: add consistency check for counts at end of process_delete_list()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 21:01:38 +0000 (22:01 +0100)]
ctdb-vacuum: log error if records are left for deletion after ctdb_process_delete_list()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 20:50:59 +0000 (21:50 +0100)]
ctdb-vacuum: use tdb_parse_record instead of tdb_fetch in delete_record_traverse()
Spare malloc and free.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:48:02 +0000 (18:48 +0100)]
ctdb-vacuum: update comment for ctdb_process_delete_queue
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:47:25 +0000 (18:47 +0100)]
ctdb-vacuum: rename ctdb_vacuum_db_fast --> ctdb_process_delete_queue
This describes more precisely what this does.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:46:49 +0000 (18:46 +0100)]
ctdb-vacuum: update comment for ctdb_vacuum_traverse_db
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:42:37 +0000 (18:42 +0100)]
ctdb-vacuum: rename ctdb_vacuum_db_full --> ctdb_vacuum_traverse_db
This describes more precisely what it actually is, nowadays.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:38:31 +0000 (18:38 +0100)]
ctdb-vacuum: change full db traverse vacuuming to fill delete queue
This lets the "fast vacuum" delete queue traverse do the actual work.
On the positive side, we note that this lets the "full vacuuming"
treat the records that have never been migrated with data correctly.
These had previously been added to the delete list for complicated
cross-node deletion instead of directly deleting them.
On the other hand side, there might be a slight overhead
since the records are read again in the delete queu traverse,
but this is OK because this change is in preparation of
untangling the db traverse altogether from the vacuum run,
making it independent.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:27:14 +0000 (18:27 +0100)]
ctdb-vacuum: run the fast vacuum after the db traverse
This in preparation of modifying the db traverse to
fill the delete_queue that is processed by the fast
vacuum run, instead of filling the same lists as the
fast vacuum run for further processing.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:08:20 +0000 (18:08 +0100)]
ctdb-vacuum: rename private->private_data in repack_traverse
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:07:55 +0000 (18:07 +0100)]
ctdb-vacuum: rename private->private_data in vacuum_traverse
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 17:03:02 +0000 (18:03 +0100)]
ctdb-vacuum: extract check for full vacuum run out of ctdb_vacuum_db_full()
This is more consistent.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 16:58:01 +0000 (17:58 +0100)]
ctdb-vacuum: add consistency check for counts to ctdb_vacuum_db_fast()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 14:28:22 +0000 (15:28 +0100)]
ctdb-vacuum: use tdb_parse_record instead of tdb_fetch in delete_queue_traverse()
this spares malloc and free
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 14:35:01 +0000 (15:35 +0100)]
ctdb-vacuum: simplify delete_record_traverse() - free treats NULL
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 14:34:23 +0000 (15:34 +0100)]
ctdb-vacuum: simplify delete_queue_traverse() - free treats NULL pointers.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 14:30:08 +0000 (15:30 +0100)]
ctdb-vacuum: reduce indentation in delete_queue_traverse
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Wed, 12 Feb 2014 16:40:31 +0000 (17:40 +0100)]
ctdb-vacuum: treat value 0 of tunable RepackLimit as turned off.
I.e. when RepackLimit is set to 0, no size of the freelist
should trigger a repack in vacuuming.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Fri, 14 Feb 2014 00:55:39 +0000 (01:55 +0100)]
ctdb-vacuum: fix treatment of remaining records and statistics in delete_record_traverse()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Wed, 12 Feb 2014 16:38:56 +0000 (17:38 +0100)]
ctdb-vacuum: cast freelist_size in comparison.
At this point, it is >= 0 anyways.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Michael Adam [Thu, 13 Feb 2014 23:53:23 +0000 (00:53 +0100)]
ctdb-vacuum: improve output of delete list statistics
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Stefan Metzmacher [Wed, 4 Dec 2013 14:32:45 +0000 (15:32 +0100)]
s3:smb2_server: avoid talloc_zero_array() in smbd_smb2_request_setup_out()
In the common case with just one request, we can use a preallocated
req->out.vector.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Mar 6 00:59:29 CET 2014 on sn-devel-104
Stefan Metzmacher [Wed, 4 Dec 2013 14:28:11 +0000 (15:28 +0100)]
s3:smb2_server: don't assume that req->out.vector is always a valid talloc pointer
We use 'req' instead as it has the same lifetime.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 14:24:29 +0000 (15:24 +0100)]
s3:smb2_server: avoid talloc_zero_array() in smbd_smb2_request_error_ex()
It is only important that the content of info->data stays alive
for the lifetime of the request, but the DATA_BLOB structure itself
can be on the stack, while passing it as 'dyn' to smbd_smb2_request_done_ex().
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 14:05:34 +0000 (15:05 +0100)]
s3:smb2_server: optimize smbd_smb2_generate_outbody() for the common case
Use a preallocated buffer for the first response in the compound chain.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_write: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_tcon: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_setinfo: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_sesssetup: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_read: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_notify: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_negprot: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_lock: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_keepalive: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_ioctl: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_getinfo: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_flush: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_find: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_create: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_close: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 13:59:07 +0000 (14:59 +0100)]
s3:smb2_break: make use of smbd_smb2_generate_outbody()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 11:52:21 +0000 (12:52 +0100)]
s3:smb2_server: add smbd_smb2_generate_outbody() helper
We can add optimization there later.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 4 Dec 2013 11:32:36 +0000 (12:32 +0100)]
s3:smb2_read: avoid 2 talloc* calls when using sendfile()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 20 Nov 2013 08:56:48 +0000 (09:56 +0100)]
s3:smb2_server: avoid a call to data_blob_clear_free() if not needed
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 20 Nov 2013 08:56:19 +0000 (09:56 +0100)]
s3:smb2_server: optimize smbd_smb2_request_setup_out()
We can use a preallocated buffer for the possible error
response of the first response in the compound chain.
This avoids a talloc_array_zero() call for the common case.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Tue, 19 Nov 2013 06:42:57 +0000 (07:42 +0100)]
s3:smb2_server: optimize req->in.vector allocation
We can avoid a talloc_zero_array() call in the
common case (without compound requests) and use a
preallocated array instead.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Fri, 6 Dec 2013 12:56:12 +0000 (13:56 +0100)]
s3:smbd: s/BUFFER_SIZE/LARGE_WRITEX_BUFFER_SIZE
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10422
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Mar 5 22:53:34 CET 2014 on sn-devel-104
Stefan Metzmacher [Wed, 5 Mar 2014 13:03:42 +0000 (14:03 +0100)]
s3:smbd: fix the maxentries calculation depending on the max_send.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 5 Mar 2014 13:00:40 +0000 (14:00 +0100)]
s3:smbd: simplify maxentries calculation in reply_search()
Using helper variables make it much easier to understand.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Tue, 4 Mar 2014 13:07:26 +0000 (14:07 +0100)]
s3:smbd: fix the read numtoread calculation depending on the max_send.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Tue, 4 Mar 2014 13:07:26 +0000 (14:07 +0100)]
s3:smbd: fix the lockread numtoread calculation depending on the max_send.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Tue, 4 Mar 2014 13:07:26 +0000 (14:07 +0100)]
s3:smbd: pass the final numtoread reply_outbuf() for the lockread reply.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Tue, 4 Mar 2014 13:07:26 +0000 (14:07 +0100)]
s3:smbd: fix lockread numtoread calculation to match reply_outbuf() arguments.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Fri, 6 Dec 2013 12:53:45 +0000 (13:53 +0100)]
s3:smbd: take less than SMB_BUFFER_SIZE_MIN ('500') as header overhead in ipc.c
We're now sure that sconn->smb1.sessions.max_send is >= SMB_BUFFER_SIZE_MIN.
in order to garantee some progress we need to make sure our assumed
header overhead is less than SMB_BUFFER_SIZE_MIN.
Assuming 372 bytes for the SMBtrans headers should still be more than
enough.
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10422
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Fri, 6 Dec 2013 12:52:09 +0000 (13:52 +0100)]
s3:smbd: reject a MaxBufferSize < SMB_BUFFER_SIZE_MIN (500) in a session setup request
This makes sure sconn->smb1.sessions.max_send is always >= SMB_BUFFER_SIZE_MIN.
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10422
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Fri, 6 Dec 2013 12:50:49 +0000 (13:50 +0100)]
s3:smbd: use sconn->smb1.sessions.max_send = SMB_BUFFER_SIZE_MAX
SMB_BUFFER_SIZE_MAX is UINT16_MAX and the largest value a client
can possibly specify in the session setup request.
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10422
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Fri, 6 Dec 2013 12:45:35 +0000 (13:45 +0100)]
s3:smbd: use SMB_BUFFER_SIZE_MIN/MAX to limit lp_max_xmit()
The current limit of 128*1024 causes problems as the value has to be
<= UINT16_MAX otherwise some clients get confused, as they want to
use the MaxBufferSize value from the negprot response (uint32_t)
for the MaxBufferSize value in thet session setup request (uint16_t).
E.g. Windows 7 (as client) sends MaxBufferSize = 0 if the server value
is > UINT16_MAX.
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10422
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Fri, 6 Dec 2013 12:57:15 +0000 (13:57 +0100)]
s3:include: let CLI_BUFFER_SIZE be an alias of SMB_BUFFER_SIZE_MAX
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10422
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Fri, 6 Dec 2013 12:28:35 +0000 (13:28 +0100)]
libcli/smb: add SMB_BUFFER_SIZE_MIN/MAX defines
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10422
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 19 Feb 2014 12:59:07 +0000 (13:59 +0100)]
s3:param: avoid using BUFFER_SIZE to limit the lp_min_receive_file_size()
There's really no reason to add such limit.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 19 Feb 2014 12:57:28 +0000 (13:57 +0100)]
s3:client: only limit the buffer by the given length 'n'
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 19 Feb 2014 12:56:06 +0000 (13:56 +0100)]
s3:torture: use CLI_BUFFER_SIZE instead of BUFFER_SIZE
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Stefan Metzmacher [Wed, 19 Feb 2014 12:54:44 +0000 (13:54 +0100)]
s3:utils/smbfilter: use a local variable for the packet buffer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Andrew Bartlett [Tue, 18 Feb 2014 22:39:46 +0000 (11:39 +1300)]
nsswitch: Remove fallback setting of WINBINDD_SOCKET_DIR
This is the original cause of the wbc NT_STATUS_OBJECT_NAME_NOT_FOUND issues in recent git master, as the
build was able to progress without the correct path being set as an override.
Andrew Bartlett
Change-Id: I1dbc7350695756356e869199b589eb781eb5c673
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Wed Mar 5 18:34:48 CET 2014 on sn-devel-104
Andrew Bartlett [Tue, 4 Mar 2014 01:11:09 +0000 (14:11 +1300)]
libcli: Add warning about flow control changing macros in ntstatus.h
Change-Id: I49fec82e55b6bc59d5c0f157df90005f7d891c66
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Garming Sam [Fri, 14 Feb 2014 05:04:22 +0000 (18:04 +1300)]
Remove all uses of the NT_STATUS_NOT_OK_RETURN_AND_FREE macro from the codebase.
Following the current coding guidelines, it is considered bad practice to return from
within a macro and change control flow as they look like normal function calls.
Change-Id: I421e169275fe323e2b019c6cc5d386289aec07f7
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Garming Sam [Fri, 14 Feb 2014 04:46:40 +0000 (17:46 +1300)]
Remove NT_STATUS_IS_ERR_RETURN macro from the codebase.
Following the current coding guidelines, it is considered bad practice to return from
within a macro and change control flow as they look like normal function calls.
Change-Id: I39b07b3a799331a5faa968629aa95b836cb78600
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Garming Sam [Fri, 14 Feb 2014 04:43:25 +0000 (17:43 +1300)]
Remove NT_STATUS_IS_OK_RETURN macro from the codebase.
Following the current coding guidelines, it is considered bad practice to return from
within a macro and change control flow as they look like normal function calls.
Change-Id: I27e7597f4078f0a6c96b5dadd12454fffe33e6b2
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Garming Sam [Thu, 13 Feb 2014 05:08:56 +0000 (18:08 +1300)]
Remove the remaining uses of the macro NT_STATUS_HAVE_NO_MEMORY_AND_FREE in the codebase.
Following the current coding guidelines, it is considered bad practice to return from
within a macro and change control flow as they look like normal function calls.
Change-Id: Id1b540cde127395a7b27385a7c0fe79f3a145c73
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Garming Sam [Thu, 13 Feb 2014 04:51:11 +0000 (17:51 +1300)]
Remove a number of NT_STATUS_HAVE_NO_MEMORY_AND_FREE macros from the codebase.
Following the current coding guidelines, it is considered bad practice to return from
within a macro and change control flow as they look like normal function calls.
Change-Id: I133eb5a699757ae57b87d3bd3ebbcf5b556b0268
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Tue, 4 Feb 2014 10:22:25 +0000 (10:22 +0000)]
winbind4: Remove unused winbind_get_idmap irpc operation
Change-Id: Ia5e62d30b277f8a7074d451cfb8675eee8e9d21f
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Tue, 4 Feb 2014 10:18:48 +0000 (10:18 +0000)]
auth4: Remove unused wbc_context
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: I07d9f7d8028429564d91da39f8d1e73cc13a646c
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Mon, 3 Feb 2014 20:36:25 +0000 (21:36 +0100)]
ntvfs_unixuid: No wbc_context required
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: I46f5d719005f3ac940482773404702368bbcfa4f
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Mon, 3 Feb 2014 20:35:05 +0000 (21:35 +0100)]
ntvfs_posix: No wbc_context required
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: Ibce7b25740cc14b0a60ad856f6b18c33115ea6fa
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Mon, 3 Feb 2014 20:33:21 +0000 (21:33 +0100)]
dcesrv_unixinfo: No wbc_context required
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: I58f01cf754e6f9a7715c0319a43ec87d8e5df194
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sun, 2 Feb 2014 14:54:53 +0000 (15:54 +0100)]
unixuid: Use the tevent_context from the ntvfs_context
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: I4edb0ee4cefdc2f1b309202c9ec70c7c7bbac0b8
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sun, 2 Feb 2014 14:53:25 +0000 (15:53 +0100)]
pvfs: Use the tevent_context from the ntvfs_context
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: Idb3ad8047d5161dd06800df611ea2a9cac84ecaa
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sun, 2 Feb 2014 14:50:08 +0000 (15:50 +0100)]
auth4: Do not generate just a temporary wbc_context
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: I16e116d7f1fdaf165e1239c10723c51f3828126d
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sun, 2 Feb 2014 14:48:03 +0000 (15:48 +0100)]
auth4: auth_session_info_fill_unix only needs a tevent_context
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: Id453d68f57bd1dd15aa5778b317d258a6132d3d6
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sun, 2 Feb 2014 14:45:47 +0000 (15:45 +0100)]
auth4: security_token_to_unix_token only needs a tevent_context
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: I27e5b38fcd3ac899c55c0632ea5d92fad686d9b1
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sun, 2 Feb 2014 14:45:13 +0000 (15:45 +0100)]
libwbclient4: Remove unused composite-based functions
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: Iff6169e35f7a82e31c42df7b2d30d122b5f67451
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sun, 2 Feb 2014 14:35:02 +0000 (15:35 +0100)]
source4: Use wbc_xids_to_sids
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: Ib1b1a7fcd881510e3fb4e5da29391e3d9392fa17
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Volker Lendecke [Sat, 1 Feb 2014 19:46:28 +0000 (20:46 +0100)]
libwbclient4: Add wbc_xids_to_sids
Signed-off-by: Volker Lendecke <vl@samba.org>
Change-Id: Ibb67f6aabd9a3fbd023ff9ec1a34d82ae599177c
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>