Incorrect file size returned in the Respond of "FILE_SUPERSEDE Create"

Jeremy Allison jra at
Wed Apr 29 10:10:31 MDT 2015

On Tue, Apr 28, 2015 at 06:29:05PM -0700, Kenny Dinh wrote:
> Jeremy,
> Using the patch you attached, and running ./bin/smbtorture against SAMBA4
> server.  After sending SUPERSEDE create, io.ntcreatex.out.create_action
> contains 0x0. However when running the test as "make test
>", I received 0x3 as the value of
> io.ntcreatex.out.create_action.  That failed the "make test"
> +
> + CHECK_VAL(io.ntcreatex.out.create_action, FILE_WAS_SUPERSEDED);
> +
> I don't understand what is the expectation.  I'm not sure how to make the test
> case work for both ./bin/smbtorture and "make test".

The problem you're running into is when you run:

make test

you're running against the (unmaintained) ntvfs file
server (which we *really* should remove from the
codebase) - which will certainly fail.

If you look at my patch carefully it has 2 hunks
in the test part. I added:

diff --git a/selftest/knownfail b/selftest/knownfail
index d4a6923..ab77e0f 100644
--- a/selftest/knownfail
+++ b/selftest/knownfail
@@ -129,6 +129,7 @@
 # some operations don't work over the CIFS NTVFS backend yet (eg. root_fid)
 ^samba4.raw.lock.*.async # bug 6960
 ^samba4.smb2.lock.*.multiple-unlock # bug 6959
 ^samba4.raw.sfileinfo.*.end-of-file\(.*\)$ # bug 6962
 ^samba4.raw.oplock.*.batch22 # bug 6963

to the knownfail file, which flags this test as expected
to fail against the ntvfs server. The test passes as expected
against smbd.

If you apply my complete patchset and just type:

make test

you'll find it passes.

Sorry for the confusion. For 4.3.x we should really
do the work and remove the alternate file server as
it's fallen too far behind smbd to be useful.

The added test passes when run manually against
Windows 2012r2 as well, which is how I know it's
good :-).



More information about the samba-technical mailing list