From owner-freebsd-questions@FreeBSD.ORG Fri Feb 10 14:50:32 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B621816A420 for ; Fri, 10 Feb 2006 14:50:32 +0000 (GMT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from smtp.infracaninophile.co.uk (ns0.infracaninophile.co.uk [81.187.76.162]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4B21D43D73 for ; Fri, 10 Feb 2006 14:50:22 +0000 (GMT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from [172.16.3.238] (gateway.ash.thebunker.net [213.129.64.4]) (authenticated bits=0) by smtp.infracaninophile.co.uk (8.13.4/8.13.4) with ESMTP id k1AEoAoo008763 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 10 Feb 2006 14:50:11 GMT (envelope-from m.seaman@infracaninophile.co.uk) Message-ID: <43ECA81C.1050302@infracaninophile.co.uk> Date: Fri, 10 Feb 2006 14:50:04 +0000 From: Matthew Seaman Organization: Infracaninophile User-Agent: Thunderbird 1.5 (X11/20060112) MIME-Version: 1.0 To: fbsd_quest@comcast.net References: <021020061420.4433.43ECA11B0001E33B0000115122028887449B9C0A9A9EA10B9C0D00@comcast.net> In-Reply-To: <021020061420.4433.43ECA11B0001E33B0000115122028887449B9C0A9A9EA10B9C0D00@comcast.net> X-Enigmail-Version: 0.94.0.0 Content-Type: multipart/signed; micalg=pgp-ripemd160; protocol="application/pgp-signature"; boundary="------------enig79DE2A0E6D215309DE332006" X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (smtp.infracaninophile.co.uk [81.187.76.162]); Fri, 10 Feb 2006 14:50:11 +0000 (GMT) X-Virus-Scanned: ClamAV 0.88/1283/Thu Feb 9 20:55:06 2006 on happy-idiot-talk.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.1.0 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on happy-idiot-talk.infracaninophile.co.uk Cc: freebsd-questions@freebsd.org Subject: Re: g_vfs_done():md2[WRITE(offset=434585600...? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Feb 2006 14:50:32 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig79DE2A0E6D215309DE332006 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable fbsd_quest@comcast.net wrote: > Hi all, >=20 > I am seeking information about what this and other similar messages > mean, and corrective action to take. At the time of the error > message, the machine spontaneously rebooted (apparently without panic > ) and came back with a corrupt /var filesystem (to which fsck > required manuall intervention to recover). >=20 > The machine is a dual Xeon ASUS NCCH-DL board with 4 GB of ram, > running 6.0 STABLE Thu Dec 222 18:24:2005, and has otherwise been > reliable. The machine was placed into test as a secondary mail > server, seeded with dictionary-attack accounts and allowed to collect > UCE and ratware at will, as a test for SpamAssassin and MIMEDefang. ( > Also makes a goot test for a pf-spamd teergrube.) >=20 > md2 is a 512mB memory disk mounted on /var/spool/MIMEDefang, to allow > quick scanning with less hardware disk IO. The main hardware drive > controller is a 3ware 4 port SATA controller in raid mirror mode. >=20 > Googling on this vfs_done() seems to show various similar requests > for information related to other circumstances but no paresable > responses. (I dont *think* md2 was ever *full*.) I can read code.. > but.. Geez, filesystem code... Echh. Clue-stick -> manpage welcome > here. Thanks. >=20 > Feb 8 13:48:59 testbed kernel: g_vfs_done():md2[WRITE(offset=3D4345856= 00, length=3D131072)]error =3D 28 > Feb 8 13:48:59 testbed kernel: g_vfs_done():md2[WRITE(offset=3D4347166= 72, length=3D131072)]error =3D 28 > Feb 8 13:48:59 testbed kernel: g_vfs_done():md2[WRITE(offset=3D4348477= 44, length=3D131072)]error =3D 28 > Feb 8 13:48:59 testbed kernel: g_vfs_done():md2[WRITE(offset=3D4349788= 16, length=3D131072)]error =3D 28 > Feb 8 13:48:59 testbed kernel: g_vfs_done():md2[WRITE(offset=3D4351098= 88, length=3D131072)]error =3D 28 > Feb 8 13:48:59 testbed kernel: g_vfs_done():md2[WRITE(offset=3D4352409= 60, length=3D131072)]error =3D 28 >=20 Did you get a kernel dump after the reboot? If you did, and you generate= d a backtrace as described here: http://www.freebsd.org/doc/en_US.ISO8859-1/books/developers-handbook/= kerneldebug-gdb.html I reckon you'ld see that it panic'd with 'kmem_map too small': #0 doadump () at pcpu.h:165 #1 0xc063ce7f in boot (howto=3D260) at /usr/src/sys/kern/kern_shutdown.c= :399 #2 0xc063d1a5 in panic (fmt=3D0xc0888692 "kmem_malloc(%ld): kmem_map too= small: % ld total allocated") at /usr/src/sys/kern/kern_shutdown.c:555 #3 0xc07aa349 in kmem_malloc (map=3D0xc10600c0, size=3D16384, flags=3D10= 26) at /usr/s rc/sys/vm/vm_kern.c:299 #4 0xc07a1c72 in page_alloc (zone=3D0x0, bytes=3D16384, pflag=3D0x0, wai= t=3D1026) at /u sr/src/sys/vm/uma_core.c:957 [etc...] It's a bug -- the VM system seems to starve the memory disk of pages, cau= sing a crash. See the example given at the end of=20 http://www.freebsd.org/cgi/query-pr.cgi?pr=3Dkern/87255 The ultimate cause would be running a bunch of programs that are heavy on= the memory requirements, and running out of memory for both them and the malloc backed memory filesystem. See mdconfig(8) -- as it says: malloc Storage for this type of memory disk is allocated wi= th malloc(9). This limits the size to the malloc buck= et limit in the kernel. If the -o reserve option is n= ot set, creating and filling a large malloc-backed mem= ory disk is a very easy way to panic a system. Hence using '-o reserve' looks like a very good thing to try. Alternativ= ely use a swap backed memory disk, or don't use a memory disk at all. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. Flat 3 7 Priory Courtyard PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate Kent, CT11 9PW, UK --------------enig79DE2A0E6D215309DE332006 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFD7Kgi8Mjk52CukIwRA3tMAKCVPC3cQQMzqbjytFUHOXphy/IjswCcCF66 jgJtR05Fw2rSyz/rQSVPO5k= =cLnm -----END PGP SIGNATURE----- --------------enig79DE2A0E6D215309DE332006--