From owner-freebsd-stable@FreeBSD.ORG Thu Feb 17 19:18:59 2005 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 330E616A4CE for ; Thu, 17 Feb 2005 19:18:59 +0000 (GMT) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.204]) by mx1.FreeBSD.org (Postfix) with ESMTP id 77A4643D31 for ; Thu, 17 Feb 2005 19:18:56 +0000 (GMT) (envelope-from swhetzel@gmail.com) Received: by wproxy.gmail.com with SMTP id 69so329251wri for ; Thu, 17 Feb 2005 11:18:55 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=kpcxmxcGI4gUQvEj4hNjY+HAtADf9fxx+tGSHocOY7lInA3vJgIGhg3Tct/4k9EBiWA40HOEpVsgQqNMc2ELgG0XjHvN390MVH+8JPL7qp3s2Cx3LOM0lsyQsZF5br3SemLfLxcpVxH83Jb5E5R6L5Uok1pPdQNDnWMue+mGQEM= Received: by 10.54.42.21 with SMTP id p21mr188773wrp; Thu, 17 Feb 2005 11:18:55 -0800 (PST) Received: by 10.54.29.8 with HTTP; Thu, 17 Feb 2005 11:18:54 -0800 (PST) Message-ID: <790a9fff05021711184a5e3e9e@mail.gmail.com> Date: Thu, 17 Feb 2005 13:18:54 -0600 From: Scot Hetzel To: Charles Erik McDonald In-Reply-To: <790a9fff0502170754793aedd4@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <42134454.7030306@mcdonald.no> <790a9fff05021607456ec0406d@mail.gmail.com> <20050216175920.4f60007c.gstewart@bonivet.net> <4213B3FD.6060400@mcdonald.no> <790a9fff0502170754793aedd4@mail.gmail.com> cc: freebsd-stable@freebsd.org Subject: Re: Strange disk problems make the system lock up X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Scot Hetzel List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Feb 2005 19:18:59 -0000 On Thu, 17 Feb 2005 09:54:01 -0600, Scot Hetzel wrote: > On Wed, 16 Feb 2005 21:58:37 +0100, Charles Erik McDonald > > So, for example: > > > > bastion(root):/usr/src#disklabel /dev/ad2 > > disklabel: /dev/ad2: no valid label found > > bastion(root):/usr/src#disklabel /dev/ad2s1 > > # /dev/ad2s1: > > 8 partitions: > > # size offset fstype [fsize bsize bps/cpg] > > c: 312576642 0 unused 0 0 # "raw" part, > > don't edit > > bastion(root):/usr/src#disklabel /dev/ad3 > > disklabel: /dev/ad3: no valid label found > > bastion(root):/usr/src#disklabel /dev/ad3s1 > > # /dev/ad3s1: > > 8 partitions: > > # size offset fstype [fsize bsize bps/cpg] > > c: 488392002 0 unused 0 0 # "raw" part, > > don't edit > > bastion(root):/usr/src# > > > you don't have any partitions on those disks. > > You need to use disklabel to create an "a" partition. > > a: 488392002 0 BSD 0 0 # > c: 488392002 0 unused 0 0 # "raw" part > To add more to my response: In FreeBSD, the disk is broken down into slices and partitions. A slice is equivalent to a DOS partition, but can be broken down into 8 partitions (a-h). The "c" partition is reserved because it is used to define the entire disk. What you need to do the following to setup /dev/ad3s1: 1. use "disklabel -e /dev/ad3s1" to add a partition (pick one a,b,d-h). If you want to use the entire slice for the partition, just copy the "c" partition numbers as: 8 partitions: # size offset fstype [fsize bsize bps/cpg] a: 488392002 0 4.2BSD 1024 8192 16 c: 488392002 0 unused 0 0 # "raw" part NOTE: for "vinium" filesystems, you need an offset of 16 8 partitions: # size offset fstype [fsize bsize bps/cpg] c: 488392002 0 unused 0 0 # "raw" part d: 488392002 16 vinium 1024 8192 16 2. use newfs on /dev/ad3s1a to put a filesystem on it. newfs /dev/ad3s1a And that should get you a working partition on your system. See the man pages on disklabel and newfs for more information. Scot