Subject: Re: overfilling mfs partitions larger than 600M causes kernel panics
To: Dan LaBell <dan4l-nospam@verizon.net>
From: Pavel Cahyna <pavel.cahyna@st.mff.cuni.cz>
List: port-macppc
Date: 11/20/2004 14:04:12
On Sat, 20 Nov 2004 05:18:05 +0000, Dan LaBell wrote:
> Anyway, I wrote a quick and dirty file copy program that used mmap for
> io. Mounted a 31 meg mfs on /tmp (swapping only to a 32meg file ) ,
> overflowed /tmp a few times, experienced only the expected outcome:
> diskfull messages. Afterwards I umounted /tmp, and did a shutdown -p
> now, after typical shutdown banter I got:
> shutdown: can't exec /sbin/halt: Exec format error.
> File on /sbin/halt says its a 'core file' of mmdup, my test program.
> Ok. now this is weird: I cp file, in order to run gdb on the core
> file, and gdb reports its not a core file, file on the copy says its an
> executable. I try gdb using /sbin/halt directly and it
> nominally works, but I can' examing anything. Looking at the file
> with a hex editor it looks like its only been partially overwritten
> with the core file. I think it has to be a result of overflowing the
> mfs. (as I did no error checking, so running out of space would
> result in a core dump, and the current directory was /tmp, which was
> mfs. )
> I going to be reboot, fsck and see if halt fixes itself. How can
> the copy be ok,
> and the original be corrupt? Is it a memory map gone awry?
>
> I don't know -- I'm just taking a wild guess, that it could be related,
> unless of course it isn't, and its something else ;-].
It sound like the problem described in PR kern/27802: on disk full,
last-edited file opened instead of binary.
Could you please append your observations to that PR?
Bye Pavel