Date: Sat, 17 May 2003 10:40:20 -0400 From: Ali Bahar <alih@internetDog.org> To: freebsd-hackers@freebsd.org Subject: Re: cache_purge > cache_zap segmentation fault Message-ID: <20030517104020.A20330@internetDog.org> In-Reply-To: <20030509104313.B1465@internetDog.org>; from alih@internetDog.org on Fri, May 09, 2003 at 10:43:13AM -0400 References: <20030508150341.B28906@internetDog.org> <1789.1052421172@critter.freebsd.dk> <20030508195410.A670@internetDog.org> <20030509064025.GA91122@walton.maths.tcd.ie> <20030509104313.B1465@internetDog.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Yup, _I_ was doing the scribbling! There was no bug in the filesystem code. There was another box running similar code, but going thru different tests. It rarely experienced this crash. So comparing the tests, it became obvious which area of our module to focus on. From there, visual inspection was enough to find the culprit. A combination of insufficient malloc size and excessive offsets, caused writes into the next heap segment. To confirm that this segment belonged to the namecache, the write address was printed while the test was carried out. ... Eventually, the seg fault occured, and the namecache node involved, was one of the write addresses. QED! The fix was tested by running the test repeatedly in batch, while running 'ls -lR /' -- which ought have exercised the namecache code mightily! ;-) Thanks much for everyone's help. regards, ali On Fri, May 09, 2003 at 10:43:13AM -0400, Ali wrote: > On Fri, May 09, 2003 at 07:40:25AM +0100, David Malone wrote: > > Is it possible that one of your modules is somehow stomping on > > memory that doesn't belong to it? > The possibility of memory overwrite by an in-development module is > about 3 orders of magnitude higher than the possibility of a name > cache bug. I can't yet see how it is happening, but I've seen weirder > coincidences in scribblers. -- Right of Return for all Palestinian refugees. Universal Declaration of Human Rights. Article 13.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030517104020.A20330>