From owner-freebsd-questions@FreeBSD.ORG Wed Feb 11 02:45:26 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 56CBC16A4CE for ; Wed, 11 Feb 2004 02:45:26 -0800 (PST) Received: from spam2.snu.ac.kr (spam2.snu.ac.kr [147.46.10.68]) by mx1.FreeBSD.org (Postfix) with SMTP id B923343D1F for ; Wed, 11 Feb 2004 02:45:25 -0800 (PST) (envelope-from nospam@users.sourceforge.net) Received: (snipe 5272 invoked by alias); 11 Feb 2004 19:45:20 +0900(KST) Received: from nospam@users.sourceforge.net with SpamSniper2.76 (Processed in 0.012011 secs); Received: from unknown (HELO sis1.snu.ac.kr) (147.46.10.36) by 0 with SMTP; 11 Feb 2004 19:45:20 +0900(KST) X-RCPTTO: freebsd-questions@freebsd.org, Received: from users.sourceforge.net (cisr.snu.ac.kr [147.46.44.181]) by sis1.snu.ac.kr (8.12.10/8.12.10) with ESMTP id i1BAg5wT138872 for ; Wed, 11 Feb 2004 19:42:05 +0900 Message-ID: <402A07C2.50005@users.sourceforge.net> Date: Wed, 11 Feb 2004 19:45:22 +0900 From: Rob User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.6) Gecko/20040207 X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-questions@freebsd.org References: <4026FBA6.8030001@users.sourceforge.net> <200402092225.35217.malcolm.kay@internode.on.net> <4027C835.1040100@users.sourceforge.net> <200402110030.49302.malcolm.kay@internode.on.net> In-Reply-To: <200402110030.49302.malcolm.kay@internode.on.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: How to safely merge two slices on harddisk? 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 10:45:26 -0000 Malcolm Kay wrote: > On Tue, 10 Feb 2004 04:19, Rob wrote: > >>Malcolm, >> >>Thank you for your detailed answer to my question. >> >>Malcolm Kay wrote: >> >>>On Mon, 9 Feb 2004 13:46, Rob wrote: >>> Do not change the offset of 'f'. If 'g' does not physically >>> follow 'f' on the disk then this is not going to work -- give up >>> now!!! >> >>How can I find that out? Is it the slice order in the disk label editor >>from /stand/sysinstall : > > > No! What you want is disklabel (see man page). On 5.x this seems to > have been replaced by bsdlabel -- but I have no experience with 5.x. The disklabel output of the disk is: ------------------------------------------------------------------------- # disklabel /dev/ad1s1c: [...zip...] 8 partitions: size offset fstype [fsize bsize bps/cpg] c:156296322 0 unused 0 0 # (Cyl. 0 - 9728*) a: 204800 0 4.2BSD 0 0 0 # (Cyl. 0 - 12*) e: 6348800 204800 4.2BSD 0 0 0 # (Cyl. 12*- 407*) f: 6348800 6553600 4.2BSD 0 0 0 # (Cyl. 407*- 803*) g: 6348800 12902400 4.2BSD 0 0 0 # (Cyl. 803*- 1198*) h: 614400 19251200 4.2BSD 0 0 0 # (Cyl. 1198*- 1236*) b: 614400 19865600 4.2BSD 2048 16384 91 # (Cyl. 1236*- 1274*) d:135816322 20480000 4.2BSD 0 0 0 # (Cyl. 1274*- 9728*) ------------------------------------------------------------------------- I have put the partitions in a new order, such that the Cyl. counts are continuously running up. Am I right, that g physically follows f here? If so, that would mean I can merge f and g into one new partition of 6 Gb, right? I actually wonder if the label editor of /stand/sysinstall can do what I want. Since I now know that f and g are back-to-front partitions, I could remove them and create a single new one; when I write this to disk, I can let sysinstall also create a new filesystem on the newly merged partition. I know this is potentially dangerous, but this way I have already deleted the swap partition, created a new ufs partition instead and created a file system on that; all in sysinstall. I believe it is safe, as long as I do not run 'newfs' on the existing partitions. Or am I missing something important here? Thanks, Rob.