Michael J. Welch, Ph.D.
2005-Feb-03 23:35 UTC
[Samba] "Delayed Write Failed" and other similar errors on Windows machines
I am experiencing an error which has been reported on the internet since Samba 2.2.7 and Windows 2000. There are many suggestions as to the cause of this problem, but no working solutions that I've been able to find. I've already invested two weeks on this problem. I was running Samba 3.0.7 under Mandrake for the last year, and this problem was not present. Because Mandrake had other bugs, and got worse upgrading from 10.0 to 10.1, I switched to SuSE 9.2 professional (boxed set). The problem does not manifest itself for the first few hours after booting, then it shows up. The only way I have found to get rid of the problem (for a short while) is to reboot Suse, an obviously unworkable workaround. I am currently running Samba 3.0.7 under SuSE, but I tried Samba 3.0.10 with no difference. My server is a Dual SMP Pentium III with 1GB RAM, a 60GB Maxtor for the system drive, and a 3Ware raid and two 80GB Maxtor drives in a RAID 1 configuration for the data drive. This is the same machine the Mandrake was running on. Here I have listed typical errors I get under the SuSE/Samba 3.0.7: [An attempt to copy a file.] The specified network name is no longer available. [The file is not copied, but the name is placed into the directory. A second attempt works normally, unless one backs out of the folder, then comes back in again, in which case the failure is repeated.] [An attempt to open a VS C++ project with no .NCB file. VS tries to build another file, but fails during the write.] Windows - Delayed Write Failed Windows was unable to save all the data for the file \\Server\icr\active\Copy of Ctrl 4-3-1-33\SKAN_Talk.ncb. The data has been lost. This error may be caused by a failure of your computer hardware or network connection. Please try to save the file elsewhere. [The file is partially created.] [An attempt to delete a file after entering the folder.] Cannot delete ~VC72: Cannot find the specified file. Make sure you specify the correct path and file name. [The file is deleted. An attempt to delete another file without first exiting and reentering the folder succeeds without any error.] I also tried booting SuSE 9.2 DVD LIVE, and I opened /tmp, then copied a file (vmlinuz) to it a half dozen times or more. After the first time, I selected OVERWRITE each time. Then I tried to delete the file, and got a message stating that the file was in use and could not be deleted. After restarting nmb/smb at the Samba server, the file could be deleted. Note that copying and overwriting the file 2 or 3 times was not enough. The file had to be overwritten at least half a dozen times or so. Since this is a SuSE to SuSE test, it eliminates Windows as the problem, and remember, the problem did not present itself under Mandrake with the same Windows client machine. Here I have listed some of the main things I have tried to fix it: In Windows XP Pro SP1, I have tried setting the registry entries for: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\... Memory Management\SystemPages HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\Lanmanserver\... Parameters\{EnableOplocks|EnableSecuritySignature) but with no effect. I also made sure that there were adequate permissions, as evidenced by the fact that the second attempts would succeed. In Samba, I changed/added the following and many other variations with no effect: [global] use sendfile = yes/no large readwrite = yes/no admin users = mike socket options = IPTOS_LOWDELAY TCP_NODELAY SO_KEEPALIVE \ SO_RCVBUF=65536 SO_SNDBUF=65536 server signing = disabled client signing = disabled level2 oplocks = yes/no locking = yes/no [each share] create mask = 0660 directory mask = 0774 oplocks = no I find it difficult to understand how this has been able to be a known (and very serious) problem for many years without being addressed and fixed. Surely someone must know the solution to this problem. Is it Samba or is it SuSE? What do I have to do to fix it? Any help will be greatly appreciated. -- Mike mjwelchphd@ekgreaders.com
Jeremy Allison
2005-Feb-05 00:11 UTC
[Samba] "Delayed Write Failed" and other similar errors on Windows machines
On Thu, Feb 03, 2005 at 03:39:30PM -0800, Michael J. Welch, Ph.D. wrote:> > [An attempt to copy a file.] > The specified network name is no longer available. > [The file is not copied, but the name is placed into the directory. > A second attempt works normally, unless one backs out of the folder, > then comes back in again, in which case the failure is repeated.] > > [An attempt to open a VS C++ project with no .NCB file. VS tries to > build another file, but fails during the write.] > Windows - Delayed Write Failed > Windows was unable to save all the data for the file > \\Server\icr\active\Copy of Ctrl 4-3-1-33\SKAN_Talk.ncb. The data has > been lost. This error may be caused by a failure of your > computer hardware or network connection. Please try to save > the file elsewhere. > [The file is partially created.]What messages are you getting in the Samba logs ? This looks like an oplock break failure or in the extreme case smbd crash. Jeremy.
Robert M. Martel
2005-Feb-11 13:49 UTC
[Samba] "Delayed Write Failed" and other similar errors on Windows machines
On 02/03/2005 06:39 PM, Michael J. Welch, Ph.D. wrote:> I am experiencing an error which has been reported on the internet > since Samba 2.2.7 and Windows 2000. There are many suggestions as...> [An attempt to open a VS C++ project with no .NCB file. VS tries to > build another file, but fails during the write.] > Windows - Delayed Write Failed > Windows was unable to save all the data for the file > \\Server\icr\active\Copy of Ctrl 4-3-1-33\SKAN_Talk.ncb. The data has > been lost. This error may be caused by a failure of your > computer hardware or network connection. Please try to save > the file elsewhere. > [The file is partially created.] >I am running Samba 3.0.10 on a Sun 420R under Solaris 9. To try to cut down the size of some user's roaming profiles I tried to re-direct the location Mozilla Mail uses to store *.msf files from the roaming profile to the user's UNIX home directory that we have mounted as h:\. I was doing this in preparation to redirect more of the roaming profile files to the UNIX home directory - I was just starting small. Anyhow, for the users that were changed I have see many "Windows Delayed Write Failed" error messages. I cannot provide any additional useful information right now - variants of SDBOT have been rampant on campus for weeks, and while the machines I administer have not been infected, attempts to infect them have kept us all busy - and put the load average on my Samba PDC through the roof - here putting local firewall rules on the Windows 2000 machines (our networking group is unwilling to block the ports I want blocked between my networks and the rest of campus.) Thus I've not had time to look for clues in the log files. I had thought that it might be due to the unusually high load averages we have been running and once that was under control the problem would go away. -Bob Martel -- *********************************************************************** Bob Martel,System Administrator I met someone who looks a lot like you Levin College of Urban Affairs She does the things you do Cleveland State University But she is an IBM (216) 687-2214 bob@urban.csuohio.edu -Jeff Lynne ***********************************************************************
Michael J. Welch, Ph.D.
2005-Feb-23 09:33 UTC
[Samba] Re: "Delayed Write Failed" and other similar errors on Windows machines
G?nter, I got the ethereal capture files under Samba, one without the "Delayed Write Error," one with, and one using Windows File server for reference. You can get them at ftp://chata.dyndns.org/DelayedWrite.zip Please see the readme.txt file. I got a big surprise when I examined the capture files. I imagine you speak German. I speak English, French, and Spanish. As far as my German goes, "Ich habt Deutsch ein der hochschule gelernt, aber ich habt alles vergessen." D?sol?e monsieur. I hope this is useful--I spent some long hours preparing it. -- Mike On Sunday 06 February 2005 17:27, you wrote:> Hello Michael, > > > On Saturday 05 February 2005 13:25, Jeremy Allison wrote: > > > Looks like it might be a hardware problem on your network then. > > > > I noticed that moving the offending folder and files on the Windoze end > > to another folder on the Samba share, the problem seemed to go away. I > > haven't had time to run any other tests, but if the the problem shows > > back up, I'll do an etherreal capture to see what can be learned. > > > > For now, case closed. Thanks. > > > > -- Mike > > -- > > sorry Mike, if you dislike getting private email resulting from public > news-groups posts. :-) > > I'm somewhat supporting the samba 4.0 team - but also watch 3.0.x. > > If your discussed problem is showing up again, feel free to contact me > directly. > > To get a chance for analysing it, you should try to catch > - a samba debug log level 10 > - an ethereal trace > > Both should be "as close to the problem as possible" - hopefully not > megabytes. You can switch the samba debuglevel (on your linux machine) with > smbcontrol smbd debug 10 > (by default this logfile is written to /var/log/samba/log.smbd) > btw - don't forget to reset that debug stuff (after sniffing the bug)! > smbcontrol smbd debug 0 > > And please, also include your used samba version. > > Maybe i can help.... > > Cheers, Guenter > > btw - you really get that error, if your "hardware link" - network cards, > cables and so on are not working properly or are out of specs. > So, also your link-speed (10 / 100 / 1000 Mbit) (full / half duplex) and > the involved switches or hubs could add some problems, too.-- Mike Michael J. Welch, Ph.D. mjwelchphd@adelphia.net or mjwelchphd@ekgreaders.com La perfection est atteinte non quand il ne reste rien ? ajouter, mais quand il ne reste rien ? enlever. --Antoine de Saint Exupery (Perfection is achieved not when there is nothing more to add, but when there is nothing left to take away.) Please, always remember, a parrot is not merely a pet. It is a child from another world. -- Bill Kiesselbach.
Apparently Analagous Threads
- "Delayed Write Failed" and other similar errors on Windows machines
- Binaries for ROracle and V 1.8. needed
- Computing time when calling C functions - why does an extra function call induce such an overhead?
- rpois gives a large number repeatedly (PR#439)
- Squirrelmail - messages not marked as read