What does sync() _really_ do?

Dave Eisen dkeisen at Gang-of-Four.Stanford.EDU
Sat Dec 29 11:53:55 AEST 1990


In article <4633 at awdprime.UUCP> tif at doorstop.austin.ibm.com (Paul Chamberlain) writes:
>dkeisen at Gang-of-Four.Stanford.EDU (Dave Eisen) writes:
>>Is unmounting a filesystem an easier way than doing enough reads from 
>>other parts of the disk to overwrite all of the buffers in the cache?
>
>I thought that it would have occurred to you while you
>were typing that, to try and define "enough".


Well, sure. But you know how many buffers there are in the cache and you
know how big each of them is. If the kernel really does use a LRU algorithm
for buffer allocation (as I understand that it does), there really is no
difficulty in figuring out how much needs to be read.



--
Dave Eisen                      	    dkeisen at Gang-of-Four.Stanford.EDU
1447 N. Shoreline Blvd.
Mountain View, CA 94043              Anybody have an extra New Year's ticket?
(415) 967-5644                             (I can hope, can't I?)



More information about the Comp.unix.internals mailing list