Bug 9640 - Mac OS X 10.7 and later cannot transfer files larger than 4.29GB to Samba
Mac OS X 10.7 and later cannot transfer files larger than 4.29GB to Samba
Product: Samba 3.6
Classification: Unclassified
Component: SMB2
All All
: P5 normal
: ---
Assigned To: Jeremy Allison
Samba QA Contact
Depends on:
  Show dependency treegraph
Reported: 2013-02-07 00:16 UTC by Joseph S. Atkinson
Modified: 2013-02-27 01:52 UTC (History)
1 user (show)

See Also:

test code.. (372 bytes, text/x-csrc)
2013-02-22 23:29 UTC, Jeremy Allison
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph S. Atkinson 2013-02-07 00:16:41 UTC
It seems that when Apple rewrote their CIFS implementation in 10.7, they changed something that breaks transfers to Samba. Transferring from Samba is fine, as is OSX <-> Windows, but OSX to Samba specifically fails.

This failure falls directly on the 32-bit threshold.

We created a test case to duplicate this and have a compressed tcpdump of this occurring.


Several other people reporting this problem with FreeNAS:

Comment 1 Björn Jacke 2013-02-07 14:31:38 UTC
can you transfer more than 4GiB to/from a Windows host?
Comment 2 Joseph S. Atkinson 2013-02-08 19:25:42 UTC
Hello Björn,

Yes. The the circumstance is specifically writes from OSX Lion to Samba. Read works as expected, as well as reads/writes to Windows from Lion.
Comment 3 Jeremy Allison 2013-02-21 19:47:48 UTC
Ok, I've taken a look at this log but unfortunately it look like the capturing system ran out of space or capacity to store the packet data.

Last reported WriteX packet is frame 6287911, a write of 65471 bytes at offset 4290376006 (0xffb9f146)/ with a mid of 2418. We see the reply to this packet saying the write succeeded at frame 6287913. But after that all your trace shows is WriteX replies, for example at frames 6288009 (mid 2419),  6288105 (mid 2420), but no more WriteX requests are shown.

So this log is incomplete and doesn't tell me what is going on.

Can you reproduce this in your offices ? If so I can probably visit next week and investigate on site.

Comment 4 Jeremy Allison 2013-02-22 23:29:22 UTC
Created attachment 8576 [details]
test code..

just so I have a record of some test code to try and reproduce.
Comment 5 Jeremy Allison 2013-02-27 01:52:15 UTC
Turns out this was due to "large readwrite = no" being set in the smb.conf, which makes the MacOSX client think it's talking to a Win9x downlevel server which doesn't do file sizes greater than 32 bit.

Removing this and leaving it at the default fixes the problem.