From owner-freebsd-arch@FreeBSD.ORG Fri Dec 17 16:21:47 2004 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C5DBB16A4CE; Fri, 17 Dec 2004 16:21:47 +0000 (GMT) Received: from duke.cs.duke.edu (duke.cs.duke.edu [152.3.140.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4DCA143D3F; Fri, 17 Dec 2004 16:21:45 +0000 (GMT) (envelope-from gallatin@cs.duke.edu) Received: from grasshopper.cs.duke.edu (grasshopper.cs.duke.edu [152.3.145.30]) by duke.cs.duke.edu (8.13.1/8.13.1) with ESMTP id iBHGLiYU026743 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 17 Dec 2004 11:21:44 -0500 (EST) Received: (from gallatin@localhost) by grasshopper.cs.duke.edu (8.12.9p2/8.12.9/Submit) id iBHGLdVQ060467; Fri, 17 Dec 2004 11:21:39 -0500 (EST) (envelope-from gallatin) From: Andrew Gallatin MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <16835.1939.301128.802993@grasshopper.cs.duke.edu> Date: Fri, 17 Dec 2004 11:21:39 -0500 (EST) To: Jun Su In-Reply-To: References: X-Mailer: VM 6.75 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid cc: alc@freebsd.org cc: arch@freebsd.org cc: tegge@freebsd.org cc: delphij@freebsd.org Subject: Re: Propose for Several Dump types X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Dec 2004 16:21:47 -0000 Jun Su writes: > Kernel-Only Dump > ============== > We now can use /dev/kmem as the core file. If we can generate a dump file with > the same information with it, then we can enable kernel-only dump with > very limit code changes. > > 1. Change KVM library to support a new type of file that only contains > kernel memory. > 2. Change kernel side to write only kernel memory when dumping. > 3. Change dumpon utility to do the right checking on the partiction size. I think the kernel-only dump is an excellent idea. But I'm confused as to how you would do it. To me, it seems like the most obvious way to do this would be walking the kernel's vm maps. But that does not work on 64-bit platforms which have a direct 1-1 physical/virtual address mapping. So how do you quickly distinguish kernel memory from user memory in the dump routine? I'm probably missing something simple.. Thanks, Drew