From owner-freebsd-questions@FreeBSD.ORG Tue Apr 8 19:04:49 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id ED720F8A for ; Tue, 8 Apr 2014 19:04:49 +0000 (UTC) Received: from bs1.fjl.org.uk (bs1.fjl.org.uk [84.45.41.196]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "bs1.fjl.org.uk", Issuer "bs1.fjl.org.uk" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4F47F16FA for ; Tue, 8 Apr 2014 19:04:49 +0000 (UTC) Received: from [192.168.1.35] (host86-150-243-51.range86-150.btcentralplus.com [86.150.243.51]) (authenticated bits=0) by bs1.fjl.org.uk (8.14.4/8.14.4) with ESMTP id s38J4e4T094936 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES128-SHA bits=128 verify=NO) for ; Tue, 8 Apr 2014 20:04:40 +0100 (BST) (envelope-from freebsd-doc@fjl.co.uk) Message-ID: <5344484C.9000504@fjl.co.uk> Date: Tue, 08 Apr 2014 20:04:44 +0100 From: Frank Leonhardt User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: "freebsd-questions@freebsd.org" Subject: Adding second drive to ZFS mirror - FreeBSD, atacontrol, gptid and documentation Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.17 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Apr 2014 19:04:50 -0000 Background: I ordered two identical drives with a view to installing FreeBSD 10 on a ZFS mirror. One drive was DOA so I sent it back and pressed on. It was replaced with an identical drive. Now I come to creating a mirrored ZFS root post-install. The new drive is there and appears in the gptid directory (I think). I have: # ls -l /dev/gptid crw-r----- 1 root operator 0x5d Mar 20 11:24 b20a8b87-9419-11e3-9063-001fc6b111fc crw-r----- 1 root operator 0x61 Mar 18 16:50 b251371d-9419-11e3-9063-001fc6b111fc I'm a little hazy about how I tie this up. I definitely have /dev/ad4p? and /dev/ad6 when I look. But this get's weird. atacontrol is missing - we're supposed to use camcontrol now, right? Okay, it's implied as being there in the release notes, but there's no man page for it and camcontrol produces: # camcontrol devlist at scbus0 target 0 lun 0 (ada0,pass0) at scbus1 target 0 lun 0 (ada1,pass1) at scbus5 target 0 lun 0 (da0,pass2) at scbus5 target 0 lun 1 (da1,pass3) at scbus5 target 0 lun 2 (da2,pass4) The top two are my babies, and they appear in /dev too. (I am certain there are NO SCSI or USB drives on this box): crw-r----- 1 root operator 0x51 Mar 18 16:50 /dev/ada0 crw-r----- 1 root operator 0x53 Mar 20 11:24 /dev/ada0p1 crw-r----- 1 root operator 0x55 Mar 18 16:50 /dev/ada0p2 crw-r----- 1 root operator 0x57 Mar 18 16:50 /dev/ada0p3 crw-r----- 1 root operator 0x5a Mar 18 16:50 /dev/ada1 What's going on? I just ran with it and tried to add the second drive as a mirror using the instructions for Solaris published by Oracle: # zpool attach zroot gptid/b251371d-9419-11e3-9063-001fc6b111fc gptid/b20a8b87-9419-11e3-9063-001fc6b111fc And for my trouble I got: cannot attach gptid/b20a8b87-9419-11e3-9063-001fc6b111fc to gptid/b251371d-9419-11e3-9063-001fc6b111fc: device is too small For completeness: # zpool status pool: zroot state: ONLINE scan: none requested config: NAME STATE READ WRITE CKSUM zroot ONLINE 0 0 0 gptid/b251371d-9419-11e3-9063-001fc6b111fc ONLINE 0 0 0 Does anyone understand this? Am I doing something wrong? The FreeBSD installer slices up the drive whereas Solaris doesn't (AFAIK) and this may relevant. In case the new drive, although theoretically identical, was actually "too small" as per the error message I checked: Old Drive: Model Family: Western Digital Red (AF) Device Model: WDC WD10EFRX-68JCSN0 Serial Number: WD-WCC1U4956043 LU WWN Device Id: 5 0014ee 2b3cb08f1 Firmware Version: 01.01A01 User Capacity: 1,000,204,886,016 bytes [1.00 TB] Sector Sizes: 512 bytes logical, 4096 bytes physical Device is: In smartctl database [for details use: -P show] ATA Version is: ATA8-ACS (minor revision not indicated) SATA Version is: SATA 3.0, 6.0 Gb/s (current: 3.0 Gb/s) New Drive: Model Family: Western Digital Red (AF) Device Model: WDC WD10EFRX-68PJCN0 Serial Number: WD-WCC4J1746659 LU WWN Device Id: 5 0014ee 25ef68b37 Firmware Version: 01.01A01 User Capacity: 1,000,204,886,016 bytes [1.00 TB] Sector Sizes: 512 bytes logical, 4096 bytes physical Rotation Rate: 5400 rpm Device is: In smartctl database [for details use: -P show] ATA Version is: ACS-2 (minor revision not indicated) SATA Version is: SATA 3.0, 6.0 Gb/s (current: 3.0 Gb/s) As I said, identical. I've obviously guessed the runes incorrectly. Help! Thanks, Frank.