From owner-freebsd-geom@FreeBSD.ORG Tue Jan 3 23:30:13 2006 Return-Path: X-Original-To: freebsd-geom@freebsd.org Delivered-To: freebsd-geom@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B6AC016A42A for ; Tue, 3 Jan 2006 23:30:13 +0000 (GMT) (envelope-from brenthostetler@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.192]) by mx1.FreeBSD.org (Postfix) with ESMTP id D9DCA43D55 for ; Tue, 3 Jan 2006 23:30:09 +0000 (GMT) (envelope-from brenthostetler@gmail.com) Received: by zproxy.gmail.com with SMTP id 9so2652220nzo for ; Tue, 03 Jan 2006 15:30:09 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=Pp3uLhiMGz6NCdeQ1IEWBRe0IqdLeh021OYwz7JqIl7YTTMNC0eVlOQF5LN2M9iebKw8hy+3kjSPX6PFgniGM7oDiyHhFvioB24qiwZ2YbGJNcGfEIKMVQAtRAW28yg9mtPNvHtGOQJlmFCFu5dLqvO5MmzflBMykeSryswvp0A= Received: by 10.36.43.13 with SMTP id q13mr4363914nzq; Tue, 03 Jan 2006 15:30:09 -0800 (PST) Received: by 10.36.88.9 with HTTP; Tue, 3 Jan 2006 15:30:08 -0800 (PST) Message-ID: Date: Tue, 3 Jan 2006 15:30:08 -0800 From: Brent Hostetler To: freebsd-geom@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Subject: Problems setting up gmirror of live system X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Jan 2006 23:30:13 -0000 ###### Hello, I am rebuilding my home server which is used to host files via Samba to wi= n XP clients throughout my house. The server is central storage for user files, = mp3, video's, etc. The current machine is running FreeBSD 5.4 with gvinum to gl= ue together 4 disks to one large disk. I have ran out of space and decided to upgrade to FreeBSD 6.0, add some more disks and add some mirroring and get away from gvinum since documentation is lack= ing. Disks to use: (2) 200 gig SATA ( same drives ) (2) 160 gig PATA ( different drives ) (2) 120 gig PATA ( same drives ) (2) 120 gig PATA ( same drives ) Idea would be to mirror the pairs and then concat or stripe the mirrors into a large partition to mount to /usr/home. I believe I can stack the Geom classes correct so this should be possible? A small portion of the first mirror would be used for the o/s partions and would be mirrored as well. I decided to start with a fresh install on the pair of 160 gig drives and try to get the mirroring going first. I believe something went wrong in step 2.2. The output of 2.7 and 2.8 should be the same, correct? I'm not sure where I messed up.. Any help appreciated. Also if I am going about this the wrong way suggestions appreciated. Thanks. Brent H. ####### 1.0 Install fresh system: Freebsd 6.0 1.1 files# uname -a FreeBSD files.hostetler.ws 6.0-RELEASE FreeBSD 6.0-RELEASE #0: Thu Nov 3 09:36:13 UTC 2005 root@x64.samsco.home:/usr/obj/usr/src/sys/GENERIC i386 1.2 files# dmesg | grep ad\[0-9\] ad4: 152627MB at ata2-master UDMA100 ad6: 152627MB at ata3-master UDMA100 Trying to mount root from ufs:/dev/ad4s1a 1.3 files# fdisk -s /dev/ad4 /dev/ad4: 310101 cyl 16 hd 63 sec Part Start Size Type Flags 1: 63 312576642 0xa5 0x80 1.4 files# bsdlabel ad4s1 # /dev/ad4s1: 8 partitions: # size offset fstype [fsize bsize bps/cpg] a: 1048576 0 4.2BSD 2048 16384 8 b: 3096576 1048576 swap c: 312576642 0 unused 0 0 # "raw" part, don't edit d: 10485760 4145152 4.2BSD 2048 16384 28552 e: 4194304 14630912 4.2BSD 2048 16384 28552 f: 83886080 18825216 4.2BSD 2048 16384 28552 g: 209865346 102711296 4.2BSD 2048 16384 28552 1.5 files# df -h Filesystem Size Used Avail Capacity Mounted on /dev/ad4s1a 496M 55M 401M 12% / /dev/ad4s1d 4.8G 12K 4.5G 0% /tmp /dev/ad4s1f 39G 1.1G 35G 3% /usr /dev/ad5s1g 97G 22K 89G 0% /usr/home /dev/ad4s1e 1.9G 1.9M 1.8G 0% /var 2.0 Follow steps at: http://people.freebsd.org/~rse/mirror 2.1 files# dd if=3D/dev/zero of=3D/dev/ad6 bs=3D512 count=3D79 79+0 records in 79+0 records out 40448 bytes transferred in 0.016785 secs (2409750 bytes/sec) 2.2 files# fdisk -v -B -I /dev/ad6 ******* Working on device /dev/ad6 ******* fdisk: invalid fdisk partition table found parameters extracted from in-core disklabel are: cylinders=3D310101 heads=3D16 sectors/track=3D63 (1008 blks/cyl) Figures below won't work with BIOS for partitions not in cyl 1 parameters to be used for BIOS calculations are: cylinders=3D310101 heads=3D16 sectors/track=3D63 (1008 blks/cyl) Information from DOS bootblock is: 1: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 63, size 312581745 (152627 Meg), flag 80 (active) beg: cyl 0/ head 1/ sector 1; end: cyl 852/ head 15/ sector 63 2: 3: 4: fdisk: Geom not found 2.3 files# gmirror label -v -n -b round-robin pair0s1 /dev/ad6s1 Metadata value stored on /dev/ad6s1. Done. 2.4 files# gmirror load 2.5 files# tail /var/log/messages Jan 3 14:51:52 files su: bch to root on /dev/ttyp0 Jan 3 14:57:11 files kernel: GEOM_MIRROR: Device pair0s1 created (id=3D1777907344). Jan 3 14:57:11 files kernel: GEOM_MIRROR: Device pair0s1: provider ad6s1 detected. Jan 3 14:57:11 files kernel: GEOM_MIRROR: Device pair0s1: provider ad6s1 activated. Jan 3 14:57:11 files kernel: GEOM_MIRROR: Device pair0s1: provider mirror/pair0s1 launched. 2.6 files# bsdlabel -w -B /dev/mirror/pair0s1 2.7 files# fdisk -s /dev/ad6 /dev/ad6: 310101 cyl 16 hd 63 sec Part Start Size Type Flags 1: 63 312581745 0xa5 0x80 2.8 files# fdisk -s /dev/ad4 /dev/ad4: 310101 cyl 16 hd 63 sec Part Start Size Type Flags 1: 63 312576642 0xa5 0x80