From owner-freebsd-current Mon Jul 17 01:06:16 1995 Return-Path: current-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id BAA11687 for current-outgoing; Mon, 17 Jul 1995 01:06:16 -0700 Received: from gndrsh.aac.dev.com (gndrsh.aac.dev.com [198.145.92.241]) by freefall.cdrom.com (8.6.10/8.6.6) with ESMTP id BAA11680 for ; Mon, 17 Jul 1995 01:06:11 -0700 Received: (from rgrimes@localhost) by gndrsh.aac.dev.com (8.6.11/8.6.9) id BAA00738; Mon, 17 Jul 1995 01:06:32 -0700 From: "Rodney W. Grimes" Message-Id: <199507170806.BAA00738@gndrsh.aac.dev.com> Subject: Re: current breaks 2.0.5 binary To: mpp@legarto.minn.net (Mike Pritchard) Date: Mon, 17 Jul 1995 01:06:32 -0700 (PDT) Cc: hsu@cs.hut.fi, davidg@Root.COM, freebsd-current@freefall.cdrom.com In-Reply-To: <199507170758.CAA03221@mpp> from "Mike Pritchard" at Jul 17, 95 02:58:39 am X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Length: 1631 Sender: current-owner@FreeBSD.org Precedence: bulk > > Rodney W. Grimes wrote: > > > >kvm_open: proc size mismatch (35520 total, 620 chunks) > > > >top: Out of memory. > > > > > > " NOTE: libkvm, w, ps, 'top', and any other utility which depends on struct > > > proc or any VM system structure will have to be rebuilt!!! " > > > > > > In addition, I had to remove /var/db/kvm_kernel.db and rebuild it. Just > > > rebuilding produced a core dump from kvm_mkdb. > > > > This is the bug that should be fixed, kvm_mkdb must be blowing up in > > the attempt to validate the current db file, it should not do that :-(. > > > > > Could it be sensible to add > > > > > > rm -f /var/db/kvm_kernel.db > > > > > > before kvm_mkdb in /etc/rc? > > > > This is a bandaid to hide the real bug, I do not want a bandaid, I want > > a real fix :-). > > > > Now the crux, I can't get kvm_mkdb to core for me :-(. > > Just for the record, I've never seen kvm_mkdb core dump, either. > But for other reasons, I would like to see the kernel database > files cleaned up. I have the following in my /etc/weekly file to > remove old kernel database files: > > find /var/db -name "kvm_*.db" -a -atime +7 -exec rm -f -- {} \; > kvm_mkdb You can get the name of the running kernel with sysctl ``kern.bootfile'' and use that information to make the find find /var/db -name "kvm_*.db" -a ! -name "${kernel}"... this totally eliminates any race condition... with that done I would say it was fine to add to /etc/weekly. -- Rod Grimes rgrimes@gndrsh.aac.dev.com Accurate Automation Company Reliable computers for FreeBSD