*BSD News Article 97721


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!lucy.swin.edu.au!news.rmit.EDU.AU!news.unimelb.edu.au!munnari.OZ.AU!news.ecn.uoknor.edu!feed1.news.erols.com!newsfeed.internetmci.com!news-was.dfn.de!news-fra1.dfn.de!news-koe1.dfn.de!RRZ.Uni-Koeln.DE!gtnduss1.du.gtn.com!www.punkt.de!not-for-mail
From: "Patrick M. Hausen" <hausen@punkt.de>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: inn-1.5.1, FBSD 2.2.0, corrupt active file
Date: 14 Jun 1997 14:56:05 GMT
Organization: WEB Internet Services
Lines: 29
Message-ID: <01bc78d3$2f8f8a20$f3e94dc2@hugo09.ticsoft.de>
References: <5nu0cp$9cd@groa.uct.ac.za>
NNTP-Posting-Host: hugo09.ticsoft.de
X-Newsreader: Microsoft Internet News 4.70.1155
Xref: euryale.cc.adfa.oz.au comp.unix.bsd.freebsd.misc:42946

Test Person <test@gmtunx.ee.uct.ac.za> wrote in
<5nu0cp$9cd@groa.uct.ac.za>...

> I've been using inn-1.5.1 with only a few newsgroups (about 5), and I 
> notice that my active file gets corrupted (a whole lot of junk gets 
> appended to the end some time while innd is running).  I recompiled
> using READ rather than MMAP, and the problem is gone.  I was wondering
> if this was a bug or merely a feature of mmap.  If it's a bug, I was 
> wondering if it works normally under 2.2.1 or 2.2.2.  The machine 
> I'm running this on has no scsi drive or adapter - just 2 ide disks.

The FreeBSD folks think, this is a bug in INN. The author of INN
thinks, since it works on SunOS, this is a bug in the semantics
of mmap() as implemented in FreeBSD.

The specification of mmap() semantics is somewhat unclear.

The SunOS manpage on mmap() leads to the conclusion that
INN is right.

To be continued ...

Patrick

P.S. The "feature/bug" that leads to garbage in your active file,
     is INN truncating a file while it's mmap()ed. As I said,
     SunOS allows this explicitly, but it doesn't work with the
     merged VM/buffer cache of FreeBSD.
     "READ" is just as fast on FreeBSD anyway.