Date: Fri, 16 Mar 2007 08:18:34 -0700 From: "Steve Franks" <stevefranks@ieee.org> To: "John Nielsen" <lists@jnielsen.net> Cc: freebsd-questions@freebsd.org Subject: Re: mirror without destroying existing contents Message-ID: <539c60b90703160818v377b9d6fia4e2b8c0fd610f6a@mail.gmail.com> In-Reply-To: <200703131541.52223.lists@jnielsen.net> References: <539c60b90703131212m731986b1p8603a86eca00d6b2@mail.gmail.com> <200703131541.52223.lists@jnielsen.net>
next in thread | previous in thread | raw e-mail | index | archive | help
I get the following: #gmirror label -v -b split -s 1024 data ad0 can't store metadata on ad0: operation not permitted. Ideas? Same behavior with /dev/ad0. Does this only work with da0 disks, not sata drives? I'm logged in as root, not su. The drive is on a promise non-raid sata card (the sw raid chipset on my asus bios lost support going from 6.1 to 6.2 - something about some new method not supported by the bios according to Soren). Thanks, Steve On 3/13/07, John Nielsen <lists@jnielsen.net> wrote: > On Tuesday 13 March 2007 15:12, Steve Franks wrote: > > Anyone made a mirror w/o destroying what's in the disk already? The > > atacontrol man page is less than adequate in this respect...is is even > > possible? > > If you want to use gmirror (which I recommend), the most conservative approach > is as follows. This can probably be adapted to other mirroring > techniques/software as well. > > Verify that your backups are up-to-date and reliable. > > Create a "degraded" single-member mirror on the blank disk (or a > partition/slice on said disk). (gmirror label command) Make sure that the > size of the disk/slice/partition is equal to or smaller than the size of the > disk/slice/partition which already contains your data. > > Create (a) new filsystem(s) on the new mirror. (newfs and possibly bsdlabel, > depending on how/if you want to break it up) > > Transfer your data from the existing filesystem to the new filesystem > (dump/restore -- it's easier than it sounds). (Alternative: restore from the > backup you created to begin with.) > > Verify data transfer, make relevant changes to /etc/fstab, possibly other > intermediate steps. > > Destroy the original filesystem (possibly using dd and /dev/zero) (not > strictly necessary, but wiping at least the first part of the > disk/slice/partition can help avoid potential confusion (for you and the > system) later.) > > Insert the original disk/slice/partition into your new mirro (gmirror insert > command). > > This approach can take longer than some others (due to the transfer > requirement), but the finished product is less likely to contain surprises. I > have successfully used this approach to migrate several types of volumes to > gmirror sets, including boot partitions. > > JN > _______________________________________________ > 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" > -- Steve Franks, KE7BTE Staff Engineer La Palma Devices, LLC http://www.lapalmadevices.com (520) 312-0089
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?539c60b90703160818v377b9d6fia4e2b8c0fd610f6a>