I found an file deletion issue in samba 3.3.14, below is the description Procedure 1. copy 10 files in samba share. 2. open and close files one by one. 3. after #3 delete closed files Phenomenon Some times files are not deleted from samba share when using Windows XP x64 SP2. Recovery Method If i erase the content of locking.tdb using tdbtool (without deleting locking.tdb) then i am able to delete the file. I am getting NT_STATUS_DELETE_PENDING error in network capture. As well as in samba log. Environment Samba 3.3.14 running on Linux FC10 Client PC where File-share has been opened is Windows XP x64 SP2 reproducibility 4/10 From my side i am trying to fix this issue, in the mean time if samba.org can help in this regard then it will be really helpful for me. :)
Created attachment 6010 [details] Attaching samba logs with level 10 Please find the debug logs. I the attached logs target file which i am trying to delete is "DOC101014-0001.xps"
Can you try with 3.5.6? 3.3.14 is not really supported by the Samba Team anymore. Volker
Dear Volkar, Thank you for the response, I understand. i will check and update bugzilla with my result. I was browsing bugzilla and found similar issue #4430 unresolved.
Dear Volker, With samba 3.5.6 i am not able to delete any files. with this configuration file. Please let me know if i missed something in configuration. [global] workgroup=Workgroup server string=SMB Server (%L) netbios name=MANOJLIN12 realm= log level=3 log file=/home/manoj/sambaInstall/sambalog/samba_%m.log max log size=64 max smbd processes=13 security=user password server= wins support=no wins proxy=no dns proxy=no map to guest=bad user client ntlmv2 auth=yes guest account=root load printers=yes local master=no encrypt passwords=yes deadtime=60 [FILE_SHARE] path=/storage/sharedfolder browseable=yes writeable=no public=no guest ok=yes available=1 Regards, Manoj
Due to "max log size = 64" the log file only contains a very small amount of the things you do. Please for debugging purposes, set "max log size = 0", stop smbd, remove the current log file, start smbd, and re-do the test. It would be great if you could also set debug hires timestamp = yes and additionally create a network trace simultaneously. Information on how to create network traces can be found under http://wiki.samba.org/index.php/Capture_Packets In particular the log file might become large, but it will shrink significantly if you compress it with bzip2 -9. Another point: I'm seeing log file messages like [2010/10/14 16:32:57, 1] locking/locking.c:parse_share_modes(503) HAPPY :data.u.s.delete_on_close -> 32 [2010/10/14 16:32:57, 1] locking/locking.c:parse_share_modes(504) HAPPY :dbuf.dptr -> [2010/10/14 16:32:57, 0] locking/locking.c:parse_share_modes(523) MANOJ :: parse_share_modes: delete_on_close: 1, owrt: Thu Oct 14 16:32:45 2010 GMT, cwrt: Thu Jan 1 09:00:00 1970 GMT, tok: 36, num_share_modes: 3 which I don't know where they come from, they are not in standard Samba. Please do your tests with a fresh compile of upstream 3.5.6. Thanks, Volker
Created attachment 6272 [details] Network Capture Password protected archive Password = 123456
Dear Volker, Sorry for making you wait for long time, I have Attached network capture "sambaFileDeletionCapture.zip" password for the capture is 123456 Also Uploaded my logs in below sharing site (Since logs size is more, I cannot upload the same in Bugzilla) <code> http://www.box.net/shared/4ruu2orttz </code> In My environment User will not have any write/edit file permission. User can only browse/delete existing files. Observation : Once this issue happened, file descriptor for thet file is still open, If I erase locking.tdb and try to delete file will get deleted. I am getting error NT_STATUS_DELETE_PENDING (This error is obvious if file is not closed properly, if i am correct). I am trying to open and close files from only one WIN-XP-Sp2 client, also from same samba share (without closing Fileshare i am opening and closing file) MY config File Looks as below [global] workgroup=Workgroup server string=SMB Server (%L) netbios name=TESTSAMBA realm= log level=100 log file=%$(AL_NET_LOG)/samba_%m.log max log size=0 max smbd processes=13 security=user password server= wins support=no wins proxy=no dns proxy=no wins server=172.16.100.6 DeviceAuthTimeout=60 map to guest=bad user client ntlmv2 auth=yes guest account=root load printers=yes printcap name=/etc/printcap printing=lprng local master=no encrypt passwords=yes deadtime=60 server signing=auto client signing=auto [FILE_SHARE] path=/storage/sharedfolder browseable=yes writeable=no public=no guest ok=yes available=1 Please let me know if you need more information. Regards Manoj
Due to some issues i cannot use samba 3.5.6, i have attached logs for Samba 3.3.14. It will be really helpful if you can tell me the issue and some work-around to avoid this situation. This issue can be reproduces easily. Very sorry for not using latest samba version. Regards Manoj
Also I cannot open the file further. Uploaded screen shots for the same in http://www.box.net/shared/4ruu2orttz Regards Manoj
Dear Volker, While further study of ethereal, we found packet number 2571 (with FID 0x1175) in attached capture doesn't have any close request. Immediately after packet 2751 I can see close req/resp for FID 0x1729, for this FID creartandxrequest is at packet number 33. Regards Manoj
Dear Volker, While further Study, I can see "Query File Internal" info for "Page0006.xps" packet number 2517 as below SMB:C; Transact2, Query File Info, Query File Internal Info, FID = 0x1774 (\DOC280211\Page0006.xps@#2515) This packet is not present for any other file deletion (Page0001.xps, Page0002.xps.......Page0005.xps). My doubt is if Samba is holding resource (File handle) in this query?? If so samba will give delete error in such case. Please clarify my doubt. Also can can you help me identifying if this packet is suppose to come or not. Thank you for spending time with this issue. Regards Manoj
Unable to reproduce this issue with samba_3.5.8. closing.