[Samba] Problem with large files

Valerio daelli valerio.daelli at gmail.com
Tue Sep 19 11:08:41 GMT 2006


Hi
we have samba 3.0.14a on FreeBSD 5.4.
We tried with different kind of locking and oplocks (both enabled and
disabled).
If we try to copy from a Windows XP client a file larger than 3g, we get
these error:

Cannot copy XXX. The specified network name is no longer available.

We traced this problem in the logs (log level 10) and we got this error

------------

[2006/09/19 10:29:41, 5] smbd/uid.c:change_to_user(281)
  change_to_user uid=(3280,3280) gid=(0,952)
[2006/09/19 10:29:41, 4] smbd/vfs.c:vfs_ChDir(660)
  vfs_ChDir to /data/exports/Services/Services
[2006/09/19 10:29:41, 10] smbd/nttrans.c:reply_ntcreate_and_X(607)
  reply_ntcreateX: flags = 0x16, desired_access = 0x20189 file_attributes =
0x80, share_access = 0x7, create_disposition = 0x1 create_options = 0x940
root_dir_fid = 0x0
[2006/09/19 10:29:41, 10] smbd/nttrans.c:map_create_disposition(341)
  map_create_disposition: Mapped create_disposition 0x1 to 0x1
[2006/09/19 10:29:41, 10] smbd/nttrans.c:map_share_mode(423)
  map_share_mode: FILE_SHARE_DELETE requested. open_mode = 0x8000
[2006/09/19 10:29:41, 10] smbd/nttrans.c:map_share_mode(480)
  map_share_mode: Mapped desired access 0x20189, share access 0x7, file
attributes 0x80 to open_mode 0x8040
[2006/09/19 10:29:41, 5] smbd/filename.c:unix_convert(108)
  unix_convert called on file "s-comp/IFOM/PROVA/Caschetto.tib"
[2006/09/19 10:29:41, 10] smbd/statcache.c:stat_cache_lookup(210)
  stat_cache_lookup: lookup failed for name
[S-COMP/IFOM/PROVA/CASCHETTO.TIB]
[2006/09/19 10:29:41, 10] smbd/statcache.c:stat_cache_lookup(210)
  stat_cache_lookup: lookup failed for name [S-COMP/IFOM/PROVA]
[2006/09/19 10:29:41, 10] smbd/statcache.c:stat_cache_lookup(210)
  stat_cache_lookup: lookup failed for name [S-COMP/IFOM]
[2006/09/19 10:29:41, 10] smbd/statcache.c:stat_cache_lookup(210)
  stat_cache_lookup: lookup failed for name [S-COMP]
[2006/09/19 10:29:41, 5] smbd/statcache.c:stat_cache_add(135)
  stat_cache_add: Added entry (8289d20:size20)
S-COMP/IFOM/PROVA/CASCHETTO.TIB -> s-comp/IFOM/PROVA/Caschetto.tib
[2006/09/19 10:29:41, 5] smbd/filename.c:unix_convert(170)
  conversion finished s-comp/IFOM/PROVA/Caschetto.tib ->
s-comp/IFOM/PROVA/Caschetto.tib
[2006/09/19 10:29:41, 3] smbd/dosmode.c:unix_mode(111)
  unix_mode(s-comp/IFOM/PROVA/Caschetto.tib) returning 0664
[2006/09/19 10:29:41, 5] smbd/files.c:file_new(129)
  allocated file structure 3875, fnum = 7971 (1 used)
[2006/09/19 10:29:41, 10] smbd/open.c:open_file_shared1(1047)
  open_file_shared: fname = s-comp/IFOM/PROVA/Caschetto.tib, dos_attrs = 80,
share_mode = 8040, ofun = 1, mode = 664, oplock request = 3
[2006/09/19 10:29:41, 8] smbd/dosmode.c:dos_mode(283)
  dos_mode: s-comp/IFOM/PROVA/Caschetto.tib
[2006/09/19 10:29:41, 8] smbd/dosmode.c:dos_mode_from_sbuf(151)
  dos_mode_from_sbuf returning
[2006/09/19 10:29:41, 8] smbd/dosmode.c:dos_mode(315)
  dos_mode returning
[2006/09/19 10:29:41, 10] locking/locking.c:get_share_modes(480)
  get_share_modes: share_mode_entry[0]: pid = 93583, share_mode = 0x11,
desired_access = 0x30196, port = 0x0, type= 0x0, file_id = 395, dev = 0x412,
inode = 6383100
[2006/09/19 10:29:41, 2] smbd/open.c:check_share_mode(530)
  Share violation on file
(4,1,1,93583,s-comp/IFOM/PROVA/Caschetto.tib,fcbopen = 0, flags = 0) = 0
[2006/09/19 10:29:41, 10] smbd/open.c:fd_open(50)
  fd_open: name s-comp/IFOM/PROVA/Caschetto.tib, flags = 00 mode = 0664, fd
= 26.
[2006/09/19 10:29:41, 2] smbd/open.c:open_file(245)
  vdaelli opened file s-comp/IFOM/PROVA/Caschetto.tib read=Yes write=No
(numopen=1)
[2006/09/19 10:29:41, 4] smbd/open.c:open_file_shared1(1204)
  open_file_shared : share_mode deny - calling open_file with flags=0x0
flags2=0x0 mode=0664 returned 1
[2006/09/19 10:29:41, 10] smbd/open.c:defer_open_sharing_error(875)
  defer_open_sharing_error: time [1158654581.742007] adding deferred open
entry for mid 52224, file s-comp/IFOM/PROVA/Caschetto.tib
[2006/09/19 10:29:41, 10]
smbd/process.c:push_sharing_violation_open_smb_message(268)
  push_sharing_violation_open_smb_message: pushing message len 154 mid 52224
timeout time [1158654582.692007]
[2006/09/19 10:29:41, 10] smbd/process.c:push_queued_message(125)
  push_message: pushed message length 154 on queue
smb_sharing_violation_queue
[2006/09/19 10:29:41, 10] locking/locking.c:add_deferred_open(1183)
  add_deferred_open: creating entry for file
s-comp/IFOM/PROVA/Caschetto.tib. num_deferred_open_entries = 1

-----------

while in this case the function get_share_modes is invoked, and we get error
there, if we copy a file smaller the function is not invoked and we don't
get any error.
In both cases ftruncate is successfullt called and we don't get any error.
Thanks for your help

Valerio Daelli


More information about the samba mailing list