On Wed, Mar 12, 2003 at 10:32:01PM +0200, Ruslan Ermilov wrote: > On Wed, Mar 12, 2003 at 02:14:25PM -0500, Andrew Gallatin wrote: > > > > I need to install current on a new box that just arrived. > > What's the latest working snapshot? > > > > 20030312-JPSNAP get about 40% of the way through the base install and > > sysinstall complains about a bad realloc, and lets me hit a key to > > reboot ;-( > > > You're just lucky. Mine just panics. > OK, I've tracked it down to the following. Kernels _without_ ``options INVARIANTS'' exhibit random panics, most often right after launching the init(8) process (or sysinstall(8), if this is an installation).
Depending on the kernel layout (I think), I saw later panics
when attempting to mount /proc, or just hanging kernel.
The attached kernel config, which is derivative of the BOOTMFS
i386 kernel which we use during installation, is such example.
It took me a while to track the problem down to a single file,
and it turned out that compiling kern/kern_malloc.c with
INVARIANTS is enough to keep the system running. Precisely,
this change did the trick:
%%%
Index: kern_malloc.c
===================================================================
RCS file: /home/ncvs/src/sys/kern/kern_malloc.c,v
retrieving revision 1.119
diff -u -p -r1.119 kern_malloc.c
--- kern_malloc.c 10 Mar 2003 20:24:54 -0000 1.119
+++ kern_malloc.c 13 Mar 2003 00:53:47 -0000
@@ -429,7 +429,7 @@ kmeminit(dummy)
char *name = kmemzones[indx].kz_name;
kmemzones[indx].kz_zone = uma_zcreate(name, size,
-#ifdef INVARIANTS
+#if 1
mtrash_ctor, mtrash_dtor, mtrash_init, mtrash_fini,
#else
NULL, NULL, NULL, NULL,
%%%
Cheers,
--
Ruslan Ermilov Sysadmin and DBA,
[EMAIL PROTECTED] Sunbay Software AG,
[EMAIL PROTECTED] FreeBSD committer,
+380.652.512.251 Simferopol, Ukraine
http://www.FreeBSD.org The Power To Serve
http://www.oracle.com Enabling The Information Age
machine i386 cpu I686_CPU ident BOOTMFS options SCHED_4BSD options INET options FFS options COMPAT_43 #options INVARIANTS options INVARIANT_SUPPORT device isa device pci device fdc device ata device atadisk device atapicd options ATA_STATIC_ID device atkbdc device atkbd device psm device vga device sc device npx device loop device ether options NO_COMPAT_FREEBSD4
pgp00000.pgp
Description: PGP signature
