From owner-freebsd-fs@FreeBSD.ORG Mon Sep 22 21:34:59 2008 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8B0961065672; Mon, 22 Sep 2008 21:34:59 +0000 (UTC) (envelope-from marck@rinet.ru) Received: from woozle.rinet.ru (woozle.rinet.ru [195.54.192.68]) by mx1.freebsd.org (Postfix) with ESMTP id 079488FC14; Mon, 22 Sep 2008 21:34:58 +0000 (UTC) (envelope-from marck@rinet.ru) Received: from localhost (localhost [127.0.0.1]) by woozle.rinet.ru (8.14.2/8.14.2) with ESMTP id m8MLYush005890; Tue, 23 Sep 2008 01:34:56 +0400 (MSD) (envelope-from marck@rinet.ru) Date: Tue, 23 Sep 2008 01:34:56 +0400 (MSD) From: Dmitry Morozovsky To: Marcel Moolenaar In-Reply-To: <10719B6B-1F3B-44C6-BAC0-D8C3F42F7F3F@mac.com> Message-ID: References: <20080921140932.adf51b5e.stas@FreeBSD.org> <10719B6B-1F3B-44C6-BAC0-D8C3F42F7F3F@mac.com> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) X-NCC-RegID: ru.rinet X-OpenPGP-Key-ID: 6B691B03 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.0 (woozle.rinet.ru [0.0.0.0]); Tue, 23 Sep 2008 01:34:56 +0400 (MSD) Cc: freebsd-fs@freebsd.org, marcel@freebsd.org Subject: Re: gpt in-place editing X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Sep 2008 21:34:59 -0000 On Mon, 22 Sep 2008, Marcel Moolenaar wrote: MM> > SS> > is there a way to split existing GPT partition into two, like one MM> > can do in MM> > SS> > bsdlabel case? MM> > SS> > MM> > SS> > I found myself wanting to shrink swap to have an alternate root, but MM> > have no MM> > SS> > luck in my experiments. MM> > SS> > MM> > SS> > For the reference, I have MM> > SS> > MM> > SS> > da0p1 boot MM> > SS> > da0p2 bootdisk MM> > SS> > da0p3 swap MM> > SS> > da0p4 ZFS MM> > SS> > MM> > SS> > and want to place two partitions in place of da0p3... MM> > SS> MM> > SS> You can simpy remove the da0p3 partition and add two new instead of MM> > it. MM> > MM> > It does not seem gpart wants allow me to delete da0p3 while disk is MM> > active... MM> MM> You probably have swapon and/or dumpon to set to the partition. MM> You can't remove a partition that is in use. MM> MM> Run "swapoff /dev/da0p3" and/or "dumpon off" first. Of course I did run swapoff; I'm not sure I did dumpoff, and unfortunately I did not run it under script(1). gpt (I did test under RELENG_7) does the trick, but -- However, we clearly have at least one bug: not creating da* device (for da0p5 in my case) Thanks. Sincerely, D.Marck [DM5020, MCK-RIPE, DM3-RIPN] [ FreeBSD committer: marck@FreeBSD.org ] ------------------------------------------------------------------------ *** Dmitry Morozovsky --- D.Marck --- Wild Woozle --- marck@rinet.ru *** ------------------------------------------------------------------------