From owner-freebsd-questions@FreeBSD.ORG Fri Jul 30 09:51:41 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 7216016A4CF for ; Fri, 30 Jul 2004 09:51:41 +0000 (GMT) Received: from smtp.infracaninophile.co.uk (ns0.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id CB22543D53 for ; Fri, 30 Jul 2004 09:51:39 +0000 (GMT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost.infracaninophile.co.uk [IPv6:::1])i6U9pVVG002744 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 30 Jul 2004 10:51:31 +0100 (BST) (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost)id i6U9pUDK002743; Fri, 30 Jul 2004 10:51:30 +0100 (BST) (envelope-from matthew) Date: Fri, 30 Jul 2004 10:51:30 +0100 From: Matthew Seaman To: Darren Pilgrim Message-ID: <20040730095130.GB1956@happy-idiot-talk.infracaninophile.co.uk> Mail-Followup-To: Matthew Seaman , Darren Pilgrim , questions@freebsd.org References: <000301c475d0$cf1ce040$132a15ac@spud> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="OwLcNYc0lM97+oe1" Content-Disposition: inline In-Reply-To: <000301c475d0$cf1ce040$132a15ac@spud> User-Agent: Mutt/1.5.6i X-Greylist: Message not sent from an IPv4 address, not delayed by milter-greylist-1.5.3 (smtp.infracaninophile.co.uk [0.0.0.0]); Fri, 30 Jul 2004 10:51:31 +0100 (BST) X-Virus-Scanned: clamd / ClamAV version devel-20040705, clamav-milter version 0.74a on smtp.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, hits=-4.8 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=2.63 X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on happy-idiot-talk.infracaninophile.co.uk cc: questions@freebsd.org Subject: Re: Different sysinstall labelling behaviour when run post-install vs. during install? 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: Fri, 30 Jul 2004 09:51:41 -0000 --OwLcNYc0lM97+oe1 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Jul 29, 2004 at 06:01:50PM -0700, Darren Pilgrim wrote: > Yesterday I was upgrading the disk in one of my workstations. Since I was > planning on growing the filesystems for my FreeBSD install at the same ti= me, > I needed to manually create a new disklabel. I used sysinstall for this, > but ran into a problem: sysinstall doesn't allocate the partition letters, > with 'a' first, if you aren't doing an initial install. I ended up using > the "auto defaults" option to create the 'a' partition, then remove > everything and create them as I wanted. I'm glad to say that it worked o= ut > just fine, but this problem raises a couple of questions: >=20 > Why does sysinstall behave differently when run post-install? Interesting. I didn't know it did that. At a guess what may be happening is that sysinstall(8) is treating your disk as if it was the second or subsequent disk on the system. In which case, it probably wouldn't allocate an 'a' partition, which by convention contains a bootable image. =20 > How do I manually specify or change the partition letter to use? Don't use sysinstall(8). sysinstall is like the training wheels children use when learning to ride a bike: essential in the beginning, but once they've achieved some proficiency, the training wheels just get in the way. Use disklabel(8), or if you're running 5.x, bsdlabel(8). It's the same program either way, it just got renamed for 5.x. disklabel will let you examine and make arbitrary edits to the disk label. You can also use it to generate a disklabel automatically. To make the sort of changes you require, use 'disklabel -e' which will put you into an editor session showing the current disk label. Then just edit the 'partitions' section as required. When creating a new partition, you must fill in the 'size', 'offset' and 'fstype' fields. for ordinary 4.2BSD (ie UFS) partitions, the next three fields are hints to newfs(8) -- the default settings (fsize=3D1024, bsize=3D8192, bps/cpg=3D16) are a good first choice, but you can modify those at will =66rom the newfs(8) commandline. The cylinder number stuff after the '#' is generated automatically: you don't need to fill anything in there yourself. Once you've revamped the partitioning, you'll need to create filesystems to go inside those partitions. newfs(8) will create you a pristine new filesystem, or if you're feeling brave, you can use growfs(8) to extend a filesystem, but a) only where the old partition starts at exactly the same offset as the new one and b) only when the new partition is *larger* than the old one. growfs(8) is more often used with such things as vinum(8) -- for plain UFS partitions dumping the filesystem, modifying the drive layout, creating new filesystems and recovering the data from backup is generally the best way to do such things, and least likely to result in foot-shooting. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK --OwLcNYc0lM97+oe1 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFBChoiiD657aJF7eIRAo/zAJ0RVfEl4T/wtwNrvolUtCnd+9ubtQCgqKNc cjx2+5VvSVm8hE5O5C27DBo= =osMp -----END PGP SIGNATURE----- --OwLcNYc0lM97+oe1--