From owner-freebsd-bugs Mon Oct 12 11:27:38 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA08948 for freebsd-bugs-outgoing; Mon, 12 Oct 1998 11:27:38 -0700 (PDT) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.15.68.22]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA08943 for ; Mon, 12 Oct 1998 11:27:35 -0700 (PDT) (envelope-from bde@godzilla.zeta.org.au) Received: (from bde@localhost) by godzilla.zeta.org.au (8.8.7/8.8.7) id EAA19765; Tue, 13 Oct 1998 04:27:16 +1000 Date: Tue, 13 Oct 1998 04:27:16 +1000 From: Bruce Evans Message-Id: <199810121827.EAA19765@godzilla.zeta.org.au> To: freebsd-bugs@FreeBSD.ORG, toasty@home.dragondata.com Subject: Re: bin/8275: w/top/etc randomly fail with 'Cannot allocate memory' Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > > "home.dragondata.com" writes: > > > bash-2.02# w > > > 1:10PM up 19 days, 54 mins, 7 users, load averages: 0.08, 0.48, 0.73 > > > USER TTY FROM LOGIN@ IDLE WHAT > > > w: kvm_getprocs: Cannot allocate memory: Cannot allocate memory > > ^^^^^^^^^^^^^^^^^^^^^^ > With 18MB free, and 60MB sitting in a cache, I can't see that I'm out of > just raw memory... Our of mbufs? Out of some fixed kind of memory? That's > what I don't know - what memory am I running out of? Probably just malloced memory. kvm_getprocs() asks the kernel for the size required to fit information about all processes. It malloc()s this size and attempts to fetch the information using another sysctl. This fails if the size required has increased, but kvm_getprocs() is too stupid to retry. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message