Return to BSD News archive
Newsgroups: comp.os.386bsd.bugs Path: sserve!newshost.anu.edu.au!munnari.oz.au!spool.mu.edu!wupost!bigboy.sbc.com!news.mtholyoke.edu!news.byu.edu!ns.novell.com!gateway.univel.com!fcom.cc.utah.edu!cs.weber.edu!terry From: terry@cs.weber.edu (A Wizard of Earth C) Subject: Re: This is a strange one! Message-ID: <1993Mar17.184040.2765@fcom.cc.utah.edu> Sender: news@fcom.cc.utah.edu Organization: Weber State University (Ogden, UT) References: <1993Mar16.102750@axion.bt.co.uk> <C40400.9qv@veda.is> Date: Wed, 17 Mar 93 18:40:40 GMT Lines: 43 In article <C40400.9qv@veda.is> root@veda.is (Tree and Root) writes: >The binaries are corrupted because other random fileblocks have replaced >parts of the binary file. This is reported to be due to the FS buffer cache >being inconsistent with the FS. [ ... ] >Do any solutions exist yet, or has the offending code at least been located? >I am prepared to dig in the code and fix it myself, if it has not been done >before. If I get stuck into this, which bits of code should I concentrate on? The *ONLY* place I have been able to duplicate this is with a system with cache (with the cache turned on) *AND* a bus-mastering disk controller that writes directly to memory (ie: controller initiated DMA). Note that not all motherboards with cache fail to invalidate the cache when memory is accessed over the bus by other than the main processor. The processor goes to read the contents of the file system buffer, and the hardware *INCORRECTLY REPORTS A CACHE HIT*! Thus the data read is not the updated data from main memory, but the previous contents of the cache which believes it holds correct data. The *ONLY* soloutions to this problem are to (1) disable the cache, (2) set jumpers so cache invalidation occurs correctly, (3) use a stupid controller that requires the main CPU to do the data transfers, or (4) replace the faulty motherboard. People, quit blaming the FS buffer cache, which is easily regression tested and proven stable, for problems resulting from inferior or incorrectly configured hardware. Terry Lambert terry@icarus.weber.edu terry_lambert@novell.com --- Any opinions in this posting are my own and not those of my present or previous employers. -- ------------------------------------------------------------------------------- "I have an 8 user poetic license" - me Get the 386bsd FAQ from agate.berkeley.edu:/pub/386BSD/386bsd-0.1/unofficial -------------------------------------------------------------------------------