From owner-freebsd-questions@FreeBSD.ORG Wed Feb 11 10:24:24 2004 Return-Path: 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 951FB16A4CE for ; Wed, 11 Feb 2004 10:24:24 -0800 (PST) Received: from clunix.cl.msu.edu (clunix.cl.msu.edu [35.9.2.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2187A43D1F for ; Wed, 11 Feb 2004 10:24:24 -0800 (PST) (envelope-from jerrymc@clunix.cl.msu.edu) Received: (from jerrymc@localhost) by clunix.cl.msu.edu (8.11.7p1+Sun/8.11.7) id i1BIOLk12779; Wed, 11 Feb 2004 13:24:21 -0500 (EST) From: Jerry McAllister Message-Id: <200402111824.i1BIOLk12779@clunix.cl.msu.edu> To: roberthuff@rcn.com (Robert Huff) Date: Wed, 11 Feb 2004 13:24:20 -0500 (EST) In-Reply-To: <16426.25589.873525.703043@jerusalem.litteratus.org> from "Robert Huff" at Feb 11, 2004 12:18:45 PM X-Mailer: ELM [version 2.5 PL2] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit cc: questions@freebsd.org Subject: Re: wiping a partition X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Feb 2004 18:24:24 -0000 > > > I've gotten into a wierd situation where the best course seems > to be wipe a (BSD) partition - without chnaging the size or location > - and then restoring from backup. > Based on the Handbook (sec. 12.3.2) the correct would seem to > be: > > make backup > cd / > dd if=/dev/zero of=/dev/da1 bs=1k count=1 > newfs -O 2 -U /dev/da1e > restore from backup > > Have I overlooked anything? That will wipe the whole da1 disk , not just a partition on it. I don't know what you really need, but something like cd / umount /dev/da1s1e newfs /dev/da1s1e would make the current stuff on the e partition of slice 1 on disk da1 unreadable short of using one of those heroic super recovery services. If you want the old stuff back, sandwich that with the backup and restore. ////jerry > > > Robert Huff >