[Samba] DOS client cannot execute BATCH file on samba share

Roberto João Lopes Garcia roberto at mha.com.br
Thu Aug 31 19:21:52 GMT 2006


Here is the logs

I do not know samba insides and could not find any info that help-me solve the problem. 

Maybe some one can help

Please note: From DOS I can type, dir and copy the test Z:\T.BAT file but can not execute it.

I did the follow.

1 - Setup a single share and mount it on a PC DOS 6 MSLANMAN as Z:
2 - Create, from PC DOS, a single T.BAT file in  Z:\
3 - At the especified time run, from PC DOS, Z:\T.BAT and record the LOG FILE

DOS REPORT:  Invalid command or file-name

I did it for debug level 3, 6 and 10.

ERRO_DOS_D3 == log level 3. Comand start at [2006/08/31 15:37:40, 3]
ERRO_DOS_D6 == log level 6. Comand start at [2006/08/31 15:42:00, 6]
ERRP_DOS_D10 == log level 10. Comand start at [2006/08/31 15:31:00, 5]

Thank you

Roberto

at 11:44 31-08-2006, Miguel Da Silva - Servicio de Informát wrote:
>Roberto João Lopes Garcia wrote:
>>Hi
>>I just upgrade from 3.0.13 to samba 3.0.23b and after upgrade DOS Lanman Clients could not execute BATCH or EXE files stored on a samba share.
>>Client can see, type and copy the file but cannot execute ! It can execute the batch file copy to C:
>>I dig a little and found: http://lists.samba.org/archive/samba/1997-November/004734.html
>>
>>>Further investigation has revealed that it seems this error is caused by
>>>the fact that smbd is unable to update the file access time, as the error
>>>happens within file_utime(). What I don't get is: Why does WinZip run?
>>>The files and directories have the same permissions... Strange
>>So I try to disable dos filetimes 
>>   dos filetimes = no
>>But did not work. 
>>I'm now seting up a server for test and see more debug messages.
>>Please, some one could help me?
>>Thank you
>>Roberto
>
>No error messages in the logs?
>
>Greetings.
>
>-- 
>Miguel Da Silva.
>Servicio de Informatica.
>Facultad de Ciencias.
>-- 
>To unsubscribe from this list go to the following URL and read the
>instructions:  https://lists.samba.org/mailman/listinfo/samba
-------------- next part --------------
[2006/08/31 15:37:40, 3] smbd/process.c:process_smb(1110)
  Transaction 17 of length 54
[2006/08/31 15:37:40, 3] smbd/process.c:switch_message(914)
  switch message SMBsearch (pid 26532) conn 0x9940f20
[2006/08/31 15:37:40, 3] smbd/dir.c:dptr_create(511)
  creating new dirptr 2 for path ., expect_close = 0
[2006/08/31 15:37:40, 3] smbd/dir.c:get_dir_entry(816)
  get_dir_entry mask=[T.BAT] found ./t.bat fname=t.bat
[2006/08/31 15:37:40, 3] smbd/process.c:process_smb(1110)
  Transaction 18 of length 69
[2006/08/31 15:37:40, 3] smbd/process.c:switch_message(914)
  switch message SMBsearch (pid 26532) conn 0x9940f20
[2006/08/31 15:37:40, 3] smbd/dir.c:dptr_fetch(696)
  fetching dirptr 2 for path . at offset 1145375056
[2006/08/31 15:37:40, 3] smbd/error.c:error_packet(162)
  error packet at smbd/reply.c(1245) cmd=129 (SMBsearch) eclass=1 ecode=18
-------------- next part --------------
[2006/08/31 15:41:17, 5] lib/util.c:show_msg(488)
  size=45
  smb_com=0x80
  smb_rcls=0
  smb_reh=0
  smb_err=0
  smb_flg=128
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=888
  smt_wct=5
  smb_vwv[ 0]=65535 (0xFFFF)
  smb_vwv[ 1]=   64 (0x40)
  smb_vwv[ 2]=  512 (0x200)
  smb_vwv[ 3]=65535 (0xFFFF)
  smb_vwv[ 4]=    0 (0x0)
  smb_bcc=0
[2006/08/31 15:42:00, 6] smbd/process.c:process_smb(1109)
  got message type 0x0 of len 0x32
[2006/08/31 15:42:00, 3] smbd/process.c:process_smb(1110)
  Transaction 7 of length 54
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(488)
  size=50
  smb_com=0x81
  smb_rcls=0
  smb_reh=0
  smb_err=0
  smb_flg=0
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=896
  smt_wct=2
  smb_vwv[ 0]=   47 (0x2F)
  smb_vwv[ 1]=   19 (0x13)
  smb_bcc=11
[2006/08/31 15:42:00, 3] smbd/process.c:switch_message(914)
  switch message SMBsearch (pid 26600) conn 0x8d88648
[2006/08/31 15:42:00, 4] smbd/uid.c:change_to_user(176)
  change_to_user: Skipping user change - already user
[2006/08/31 15:42:00, 5] smbd/filename.c:unix_convert(108)
  unix_convert called on file "T.BAT"
[2006/08/31 15:42:00, 5] smbd/filename.c:unix_convert(185)
  unix_convert begin: name = T.BAT, dirpath = , start = T.BAT
[2006/08/31 15:42:00, 5] smbd/statcache.c:stat_cache_add(140)
  stat_cache_add: Added entry (8d22d20:size6) T.BAT -> t.bat
[2006/08/31 15:42:00, 5] smbd/statcache.c:stat_cache_add(140)
  stat_cache_add: Added entry (8d22d20:size6) T.BAT -> t.bat
[2006/08/31 15:42:00, 5] smbd/filename.c:unix_convert(400)
  conversion finished T.BAT -> t.bat
[2006/08/31 15:42:00, 5] smbd/dir.c:dptr_create(391)
  dptr_create dir=.
[2006/08/31 15:42:00, 3] smbd/dir.c:dptr_create(511)
  creating new dirptr 2 for path ., expect_close = 0
[2006/08/31 15:42:00, 4] smbd/reply.c:reply_search(1186)
  dptr_num is 2
[2006/08/31 15:42:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8d82b80 now at offset 0
[2006/08/31 15:42:00, 5] smbd/mangle_hash.c:name_map(615)
  name_map( ., need83 = True, cache83 = False)
[2006/08/31 15:42:00, 5] smbd/mangle_hash.c:name_map(641)
  name_map() ==> [.]
[2006/08/31 15:42:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8d82b80 now at offset -2147483648
[2006/08/31 15:42:00, 5] smbd/mangle_hash.c:name_map(615)
  name_map( .., need83 = True, cache83 = False)
[2006/08/31 15:42:00, 5] smbd/mangle_hash.c:name_map(641)
  name_map() ==> [..]
[2006/08/31 15:42:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8d82b80 now at offset 1145375056
[2006/08/31 15:42:00, 3] smbd/dir.c:get_dir_entry(816)
  get_dir_entry mask=[T.BAT] found ./t.bat fname=t.bat
[2006/08/31 15:42:00, 6] smbd/dir.c:dptr_fill(666)
  fill on key 2 dirptr 0x8cc95d8 now at 1145375056
[2006/08/31 15:42:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8d82b80 now at offset -1
[2006/08/31 15:42:00, 4] smbd/reply.c:reply_search(1270)
  SMBsearch mask=T.BAT path=. dtype=19 nument=1 of 47
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(488)
  size=83
  smb_com=0x81
  smb_rcls=0
  smb_reh=0
  smb_err=0
  smb_flg=128
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=896
  smt_wct=1
  smb_vwv[ 0]=    1 (0x1)
  smb_bcc=46
[2006/08/31 15:42:00, 6] smbd/process.c:process_smb(1109)
  got message type 0x0 of len 0x41
[2006/08/31 15:42:00, 3] smbd/process.c:process_smb(1110)
  Transaction 8 of length 69
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(488)
  size=65
  smb_com=0x81
  smb_rcls=0
  smb_reh=0
  smb_err=0
  smb_flg=0
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=904
  smt_wct=2
  smb_vwv[ 0]=   47 (0x2F)
  smb_vwv[ 1]=   19 (0x13)
  smb_bcc=26
[2006/08/31 15:42:00, 3] smbd/process.c:switch_message(914)
  switch message SMBsearch (pid 26600) conn 0x8d88648
[2006/08/31 15:42:00, 4] smbd/uid.c:change_to_user(176)
  change_to_user: Skipping user change - already user
[2006/08/31 15:42:00, 3] smbd/dir.c:dptr_fetch(696)
  fetching dirptr 2 for path . at offset 1145375056
[2006/08/31 15:42:00, 4] smbd/reply.c:reply_search(1186)
  dptr_num is 2
[2006/08/31 15:42:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8d82b80 now at offset -1
[2006/08/31 15:42:00, 4] smbd/dir.c:dptr_close_internal(238)
  closing dptr key 2
[2006/08/31 15:42:00, 3] smbd/error.c:error_packet(162)
  error packet at smbd/reply.c(1245) cmd=129 (SMBsearch) eclass=1 ecode=18
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:42:00, 5] lib/util.c:show_msg(488)
  size=35
  smb_com=0x81
  smb_rcls=1
  smb_reh=0
  smb_err=18
  smb_flg=128
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=904
  smt_wct=0
  smb_bcc=0
[2006/08/31 15:43:00, 3] smbd/sec_ctx.c:set_sec_ctx(241)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2006/08/31 15:43:00, 5] auth/auth_util.c:debug_nt_user_token(448)
  NT user token: (NULL)
[2006/08/31 15:43:00, 5] auth/auth_util.c:debug_unix_user_token(474)
  UNIX token of user 0
  Primary group is 0 and contains 0 supplementary groups
[2006/08/31 15:43:00, 5] smbd/uid.c:change_to_root_user(275)
  change_to_root_user: now uid=(0,0) gid=(0,0)
-------------- next part --------------
[2006/08/31 15:30:00, 10] smbd/process.c:setup_select_timeout(1284)
  change_notify_timeout: -1
[2006/08/31 15:31:00, 3] smbd/sec_ctx.c:set_sec_ctx(241)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2006/08/31 15:31:00, 5] auth/auth_util.c:debug_nt_user_token(448)
  NT user token: (NULL)
[2006/08/31 15:31:00, 5] auth/auth_util.c:debug_unix_user_token(474)
  UNIX token of user 0
  Primary group is 0 and contains 0 supplementary groups
[2006/08/31 15:31:00, 5] smbd/uid.c:change_to_root_user(275)
  change_to_root_user: now uid=(0,0) gid=(0,0)
[2006/08/31 15:31:00, 10] smbd/process.c:setup_select_timeout(1284)
  change_notify_timeout: -1
[2006/08/31 15:31:00, 10] lib/util_sock.c:read_smb_length_return_keepalive(623)
  got smb length of 50
[2006/08/31 15:31:00, 6] smbd/process.c:process_smb(1109)
  got message type 0x0 of len 0x32
[2006/08/31 15:31:00, 3] smbd/process.c:process_smb(1110)
  Transaction 5 of length 54
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(488)
  size=50
  smb_com=0x81
  smb_rcls=0
  smb_reh=0
  smb_err=0
  smb_flg=0
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=688
  smt_wct=2
  smb_vwv[ 0]=   47 (0x2F)
  smb_vwv[ 1]=   19 (0x13)
  smb_bcc=11
[2006/08/31 15:31:00, 10] lib/util.c:dump_data(2215)
  [000] 04 5C 54 2E 42 41 54 00  05 00 00                 .\T.BAT. ...
[2006/08/31 15:31:00, 3] smbd/process.c:switch_message(914)
  switch message SMBsearch (pid 26455) conn 0x8c6d670
[2006/08/31 15:31:00, 3] smbd/sec_ctx.c:set_sec_ctx(241)
  setting sec ctx (1001, 1111) - sec_ctx_stack_ndx = 0
[2006/08/31 15:31:00, 5] auth/auth_util.c:debug_nt_user_token(454)
  NT user token of user S-1-5-21-4075959373-3079715723-1127318269-3002
  contains 17 SIDs
  SID[  0]: S-1-5-21-4075959373-3079715723-1127318269-3002
  SID[  1]: S-1-5-21-4075959373-3079715723-1127318269-3223
  SID[  2]: S-1-1-0
  SID[  3]: S-1-5-2
  SID[  4]: S-1-5-11
  SID[  5]: S-1-5-21-4075959373-3079715723-1127318269-3201
  SID[  6]: S-1-5-21-4075959373-3079715723-1127318269-3203
  SID[  7]: S-1-5-21-4075959373-3079715723-1127318269-3225
  SID[  8]: S-1-5-21-4075959373-3079715723-1127318269-3227
  SID[  9]: S-1-5-21-4075959373-3079715723-1127318269-3229
  SID[ 10]: S-1-5-21-4075959373-3079715723-1127318269-3231
  SID[ 11]: S-1-5-21-4075959373-3079715723-1127318269-3233
  SID[ 12]: S-1-5-21-4075959373-3079715723-1127318269-3235
  SID[ 13]: S-1-5-21-4075959373-3079715723-1127318269-3237
  SID[ 14]: S-1-5-21-4075959373-3079715723-1127318269-3239
  SID[ 15]: S-1-5-21-4075959373-3079715723-1127318269-3241
  SID[ 16]: S-1-5-21-4075959373-3079715723-1127318269-3243
  SE_PRIV  0x0 0x0 0x0 0x0
[2006/08/31 15:31:00, 5] auth/auth_util.c:debug_unix_user_token(474)
  UNIX token of user 1001
  Primary group is 1111 and contains 13 supplementary groups
  Group[  0]: 1111
  Group[  1]: 1100
  Group[  2]: 1101
  Group[  3]: 1112
  Group[  4]: 1113
  Group[  5]: 1114
  Group[  6]: 1115
  Group[  7]: 1116
  Group[  8]: 1117
  Group[  9]: 1118
  Group[ 10]: 1119
  Group[ 11]: 1120
  Group[ 12]: 1121
[2006/08/31 15:31:00, 5] smbd/uid.c:change_to_user(260)
  change_to_user uid=(1001,1001) gid=(0,1111)
[2006/08/31 15:31:00, 5] smbd/filename.c:unix_convert(108)
  unix_convert called on file "T.BAT"
[2006/08/31 15:31:00, 10] smbd/statcache.c:stat_cache_lookup(248)
  stat_cache_lookup: lookup succeeded for name [T.BAT] -> [t.bat]
[2006/08/31 15:31:00, 5] smbd/dir.c:dptr_create(391)
  dptr_create dir=.
[2006/08/31 15:31:00, 3] smbd/dir.c:dptr_create(511)
  creating new dirptr 1 for path ., expect_close = 0
[2006/08/31 15:31:00, 4] smbd/reply.c:reply_search(1186)
  dptr_num is 1
[2006/08/31 15:31:00, 8] smbd/reply.c:reply_search(1204)
  dirpath=<.> dontdescend=<>
[2006/08/31 15:31:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8bc64f8 now at offset 0
[2006/08/31 15:31:00, 5] smbd/mangle_hash.c:name_map(615)
  name_map( ., need83 = True, cache83 = False)
[2006/08/31 15:31:00, 5] smbd/mangle_hash.c:name_map(641)
  name_map() ==> [.]
[2006/08/31 15:31:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8bc64f8 now at offset -2147483648
[2006/08/31 15:31:00, 5] smbd/mangle_hash.c:name_map(615)
  name_map( .., need83 = True, cache83 = False)
[2006/08/31 15:31:00, 5] smbd/mangle_hash.c:name_map(641)
  name_map() ==> [..]
[2006/08/31 15:31:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8bc64f8 now at offset 1145375056
[2006/08/31 15:31:00, 8] smbd/dosmode.c:dos_mode(377)
  dos_mode: ./t.bat
[2006/08/31 15:31:00, 8] smbd/dosmode.c:dos_mode_from_sbuf(193)
  dos_mode_from_sbuf returning 
[2006/08/31 15:31:00, 8] smbd/dosmode.c:dos_mode(415)
  dos_mode returning 
[2006/08/31 15:31:00, 3] smbd/dir.c:get_dir_entry(816)
  get_dir_entry mask=[T.BAT] found ./t.bat fname=t.bat
[2006/08/31 15:31:00, 8] smbd/dir.c:make_dir_struct(103)
  put name [t.bat] from [t.bat] into dir struct
[2006/08/31 15:31:00, 6] smbd/dir.c:dptr_fill(666)
  fill on key 1 dirptr 0x8c688d8 now at 1145375056
[2006/08/31 15:31:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8bc64f8 now at offset -1
[2006/08/31 15:31:00, 4] smbd/reply.c:reply_search(1270)
  SMBsearch mask=T.BAT path=. dtype=19 nument=1 of 47
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(488)
  size=83
  smb_com=0x81
  smb_rcls=0
  smb_reh=0
  smb_err=0
  smb_flg=128
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=688
  smt_wct=1
  smb_vwv[ 0]=    1 (0x1)
  smb_bcc=46
[2006/08/31 15:31:00, 10] lib/util.c:dump_data(2215)
  [000] 05 2B 00 13 54 20 20 20  20 20 20 20 42 41 54 01  .+..T        BAT.
  [010] 50 09 45 44 00 00 00 00  00 A9 74 1F 35 2B 00 00  P.ED.... .©t.5+..
  [020] 00 74 2E 62 61 74 00 00  00 00 00 00 00 00        .t.bat.. ......
[2006/08/31 15:31:00, 10] smbd/process.c:setup_select_timeout(1284)
  change_notify_timeout: -1
[2006/08/31 15:31:00, 10] lib/util_sock.c:read_smb_length_return_keepalive(623)
  got smb length of 65
[2006/08/31 15:31:00, 6] smbd/process.c:process_smb(1109)
  got message type 0x0 of len 0x41
[2006/08/31 15:31:00, 3] smbd/process.c:process_smb(1110)
  Transaction 6 of length 69
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(488)
  size=65
  smb_com=0x81
  smb_rcls=0
  smb_reh=0
  smb_err=0
  smb_flg=0
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=696
  smt_wct=2
  smb_vwv[ 0]=   47 (0x2F)
  smb_vwv[ 1]=   19 (0x13)
  smb_bcc=26
[2006/08/31 15:31:00, 10] lib/util.c:dump_data(2215)
  [000] 04 00 05 15 00 13 54 20  20 20 20 20 20 20 42 41  ......T        BA
  [010] 54 01 50 09 45 44 06 00  10 24                    T.P.ED.. .$
[2006/08/31 15:31:00, 3] smbd/process.c:switch_message(914)
  switch message SMBsearch (pid 26455) conn 0x8c6d670
[2006/08/31 15:31:00, 4] smbd/uid.c:change_to_user(176)
  change_to_user: Skipping user change - already user
[2006/08/31 15:31:00, 3] smbd/dir.c:dptr_fetch(696)
  fetching dirptr 1 for path . at offset 1145375056
[2006/08/31 15:31:00, 4] smbd/reply.c:reply_search(1186)
  dptr_num is 1
[2006/08/31 15:31:00, 8] smbd/reply.c:reply_search(1204)
  dirpath=<.> dontdescend=<>
[2006/08/31 15:31:00, 6] smbd/dir.c:get_dir_entry(775)
  readdir on dirptr 0x8bc64f8 now at offset -1
[2006/08/31 15:31:00, 4] smbd/dir.c:dptr_close_internal(238)
  closing dptr key 1
[2006/08/31 15:31:00, 3] smbd/error.c:error_packet(162)
  error packet at smbd/reply.c(1245) cmd=129 (SMBsearch) eclass=1 ecode=18
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(478)
[2006/08/31 15:31:00, 5] lib/util.c:show_msg(488)
  size=35
  smb_com=0x81
  smb_rcls=1
  smb_reh=0
  smb_err=18
  smb_flg=128
  smb_flg2=1
  smb_tid=1
  smb_pid=4331
  smb_uid=100
  smb_mid=696
  smt_wct=0
  smb_bcc=0
[2006/08/31 15:31:00, 10] smbd/process.c:setup_select_timeout(1284)
  change_notify_timeout: -1
[2006/08/31 15:32:00, 3] smbd/sec_ctx.c:set_sec_ctx(241)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2006/08/31 15:32:00, 5] auth/auth_util.c:debug_nt_user_token(448)
  NT user token: (NULL)
[2006/08/31 15:32:00, 5] auth/auth_util.c:debug_unix_user_token(474)
  UNIX token of user 0
  Primary group is 0 and contains 0 supplementary groups


More information about the samba mailing list