[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sync

From: Bob Proulx
Subject: Re: sync
Date: Thu, 25 Apr 2002 22:59:49 -0600

> I believe sync caused me trouble.

The sync command line program calls the sync(2) operating system
kernel routine.  That kernel routine writes any unwritten data that
has been written by application programs to their final destination.
This is normally done by an operating system daemon program
regularly.  Frequently that is called 'syncer' but on linux it is
called 'bdflush' and 'kflush'.  That ensures that any data written by
program but which is still buffered in memory will eventually get
pushed through and written to the disk.  

The command line program and other programs which call this are there
to cause the write to happen immediately.  Even if you did not call
sync it would eventually get called by the background process.
Calling the command line just causes it to happen right now.

I am not sure why you had an error on your computer.  It could be
something simple like a piece of dirt which caused trouble with the
floppy disk.  Or it could have been a parity error in the ram.  It is
impossible to know at this time.

Computers have always been a source of frustration when a crash
happens and data has not been fully saved to disk.  Therefore the
saying, save early, save often, and keep a separate backup, has been a
long standing tradition among computer users.


> I've used a partucular floppy (1.44 MB 3.5" - CLASSIC HD) for some time. 
> Lets say 3 months and I write a journal/diary on it. I would say that 
> for an average I write to it 2-3 times a day, and read from it once a 
> day. I carry this disc between a DELL win 98, office 97 pc at home and a 
> FUJITSU-SIEMENS Lifebook S Series running Debian Linux 2.4.18 with a 
> FUJITSU floppy 3.5" FDD unit Model FPCFDD02 ; P/N CA02950-1482 ; S/N 
> 08Q058-2498. I am entirely sure that I had never used sync before this 
> occasion and also that the file I was editing wore no sign of trouble 
> before this and that the problem existed exactly after the sync 
> operation. Furthermore. There are about 15 other files on this floppy 
> and the file in question was the only one opened at this moment and all 
> the other ones are okay. If I would like to trust sync and blame someone 
> else it would demand that this was due to overusage of the floppy and 
> that the problem occured at the same time on exactly this file from pure 
> insidence. Since I cannot believe this (I'd be chocked by someone who 
> did) I believe sync did it. Statistically I am definately right. The 
> floppy unit and the floppy disc appears to be working just fine afterwards.
> I was editing a rtf-file with Staroffice 5.2 at this moment.
> The lost work can be reedited with 10 minutes of double work. I am not 
> crying but I am nourishing the hope that LINUX will turn out to be the 
> superior operating system.
> Analysis of the file shows that it appears to be simply cut at a late 
> point. After 95% och the text I would estimate. This analysis was done 
> by typing 'PROMPTER> cat april2002 > x.txt ; vi x.txt'. It could not be 
> read by staroffice (or word) cause there is now a format error if it is 
> to be interpreted as RTF.
> My friend who hinted me about sync receives a copy of this e-mail. I 
> wanted to flush my file to disc in some better way than unmounting and 
> then mounting it back.
> I would be interested if there is any knowledge about this problem or if 
> I can help you further.
> Kind regards,
> Kåre Jonsson

reply via email to

[Prev in Thread] Current Thread [Next in Thread]