From owner-freebsd-questions@FreeBSD.ORG Sun Sep 2 04:18:19 2007 Return-Path: Delivered-To: freebsd-questions@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F077016A420 for ; Sun, 2 Sep 2007 04:18:17 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from gaia.nimnet.asn.au (nimbin.lnk.telstra.net [139.130.45.143]) by mx1.freebsd.org (Postfix) with ESMTP id 153A313C4E5 for ; Sun, 2 Sep 2007 04:18:14 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from localhost (smithi@localhost) by gaia.nimnet.asn.au (8.8.8/8.8.8R1.5) with SMTP id OAA17023; Sun, 2 Sep 2007 14:00:06 +1000 (EST) (envelope-from smithi@nimnet.asn.au) Date: Sun, 2 Sep 2007 14:00:05 +1000 (EST) From: Ian Smith To: Kris Kennaway In-Reply-To: <20070902000629.3FE7016A4C1@hub.freebsd.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: freebsd-questions@FreeBSD.org Subject: Re: g_vfs write error = 28, bad memory? 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: Sun, 02 Sep 2007 04:18:19 -0000 On Sat, 01 Sep 2007 19:34:41 +0200 Kris Kennaway wrote: > Per olof Ljungmark wrote: > > Kris Kennaway wrote: > >> Per olof Ljungmark wrote: > >>> Kris Kennaway wrote: > >>>> Per olof Ljungmark wrote: > >>>>> I use a memory file system for some tmp files and last night I saw > >>>>> this, followed by a reboot. Bad memory? 6-STABLE from April.. > >>>>> > >>>>> foo-bar kernel: g_vfs_done():md0[WRITE(offset=259244032, > >>>>> length=131072)]error = 28 > >>>>> foo-bar kernel: g_vfs_done():md0[WRITE(offset=259375104, > >>>>> length=131072)]error = 28 > >>>>> [ten more lines...] > >>>>> [reboot] > >>>>> > >>>>> Thanks, > >>>> > >>>> #define ENOSPC 28 /* No space left on device */ > >>>> > >>>> You are probably (incorrectly) using a malloc backed disk. Use swap > >>>> backing and you won't panic when memory is low. > >>> > >>> Yes, sounds likely, thanks. One more question then, where is the md > >>> information stored through a reboot? I did not edit rc.conf or fstab > >>> or kernel config but still /dev/md0 came back up. Hmmm. > >> > >> It's not, unless something is explicitly creating it each time you > >> boot. Perhaps you are using a rc.conf setting that creates a md /tmp. > > > > Indeed, here it was: > > > > amavisd_enable="YES" > > amavisd_ram="512m" > > > > and the line in rc.d/amavisd > > mdmfs -M -s ${amavisd_ram} -w vscan:vscan md /var/amavis/tmp || true > > for some reason creates a malloc based mfs > > > > Perhaps I should check this with the maintainer... > > > > > > Yes, malloc backing for md should be used in almost no situations. Am I right in thinking such situations would then be limited to diskless / flashdisk / embedded systems having no swap? Seems obvious, but .. Cheers, Ian