From owner-freebsd-questions@FreeBSD.ORG Mon Aug 25 20:54:32 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 326961065671 for ; Mon, 25 Aug 2008 20:54:32 +0000 (UTC) (envelope-from lists@jnielsen.net) Received: from ns1.jnielsen.net (ns1.jnielsen.net [69.55.238.237]) by mx1.freebsd.org (Postfix) with ESMTP id 0908A8FC1C for ; Mon, 25 Aug 2008 20:54:31 +0000 (UTC) (envelope-from lists@jnielsen.net) Received: from [10.3.4.15] (rrcs-74-218-226-253.se.biz.rr.com [74.218.226.253]) (authenticated bits=0) by ns1.jnielsen.net (8.12.9p2/8.12.9) with ESMTP id m7PKsU1r002196; Mon, 25 Aug 2008 16:54:30 -0400 (EDT) (envelope-from lists@jnielsen.net) From: John Nielsen To: freebsd-questions@freebsd.org Date: Mon, 25 Aug 2008 16:54:17 -0400 User-Agent: KMail/1.9.9 References: <48B186B3.4030803@stupar.homelinux.net> <20080825143507.A9361@wojtek.tensor.gdynia.pl> <1219679441.2701.19.camel@frodon.be-bif.ulb.ac.be> In-Reply-To: <1219679441.2701.19.camel@frodon.be-bif.ulb.ac.be> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200808251654.17772.lists@jnielsen.net> X-Virus-Scanned: ClamAV version 0.88.4, clamav-milter version 0.88.4 on ns1.jnielsen.net X-Virus-Status: Clean Cc: Julien Cigar Subject: Re: Cloning a gmirrored hard drive X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Aug 2008 20:54:32 -0000 On Monday 25 August 2008 11:50:41 am Julien Cigar wrote: > Stupid question: can't you use growfs on the existing gmirror (after > replace /dev/oneofdisk, resync, replace /dev/otherdisk, resync) ? > Is it mandatory to create a *new* gmirror ? There is no way to resize a gmirror provider without creating a new one. You could possibly insert the new large drive into the mirror, deactivate it, make a new gmirror on it (clobbering the old one), THEN use growfs.. but that's a lot mor ecomplicated and error-prone than doing it the right way using dump/restore. If downtime is a concern then use Ivan's method below but without going into single-user--just be sure to give -L to dump. > On Mon, 2008-08-25 at 14:37 +0200, Wojciech Puchar wrote: > > >> Hi! > > >> > > >> My situation: I have a server with FBSD 7 installed with two 40 GB > > >> disks in RAID 1 (gmirror) config. > > >> Now I have noticed the lack of space on the drive so I am thinking > > >> to change these disks for two 160 GB. > > >> What is the best way to clone the main hard disk in raid 1 config? > > >> Is > > > > gmirror remove yourmirrorname /dev/oneofdisk > > > > shutdown and replace this one with 160GB > > > > boot single user > > > > make gmirror with this new 160GB drive (only one drive now so not > > real mirror) > > > > newfs and copy all data make it bootable, shutdown, remove second > > 40GB drive, add second 160GB drive, boot and then > > > > gmirror insert yournewmirror seconddrive > > > > that's all. > > _______________________________________________ > > freebsd-questions@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > > To unsubscribe, send any mail to > > "freebsd-questions-unsubscribe@freebsd.org"