From owner-freebsd-current@FreeBSD.ORG Sat Nov 2 06:15:00 2013 Return-Path: Delivered-To: freebsd-current@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 ESMTP id D78EE493; Sat, 2 Nov 2013 06:15:00 +0000 (UTC) (envelope-from Devin.Teske@fisglobal.com) Received: from mx1.fisglobal.com (mx1.fisglobal.com [199.200.24.190]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 9960F235F; Sat, 2 Nov 2013 06:15:00 +0000 (UTC) Received: from smtp.fisglobal.com ([10.132.206.31]) by ltcfislmsgpa03.fnfis.com (8.14.5/8.14.5) with ESMTP id rA26EsLv014207 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NOT); Sat, 2 Nov 2013 01:14:54 -0500 Received: from LTCFISWMSGMB21.FNFIS.com ([169.254.1.152]) by LTCFISWMSGHT03.FNFIS.com ([10.132.206.31]) with mapi id 14.03.0158.001; Sat, 2 Nov 2013 01:14:52 -0500 From: "Teske, Devin" To: Allan Jude Subject: Re: [CFT] Patch to bsdinstall to support root-on-ZFS and GELI Thread-Topic: [CFT] Patch to bsdinstall to support root-on-ZFS and GELI Thread-Index: AQHOzOHuoyZqOu2cyEmJYHyn2Q5Miw== Date: Sat, 2 Nov 2013 06:14:52 +0000 Message-ID: References: <52629DA7.7090103@bridgenet.se> <5262A3EE.4050600@allanjude.com> <5262A5D0.3050604@bridgenet.se> <5262A69D.5070601@allanjude.com> <13CA24D6AB415D428143D44749F57D720FC7E9DE@LTCFISWMSGMB21.FNFIS.com> <13CA24D6AB415D428143D44749F57D720FC7EAEC@LTCFISWMSGMB21.FNFIS.com> <5262B304.3090605@allanjude.com> <5262BC56.4050004@bridgenet.se> <13CA24D6AB415D428143D44749F57D720FC7F916@LTCFISWMSGMB21.FNFIS.com> <52654C0C.80702@bridgenet.se> <52654D47.6020106@allanjude.com> <13CA24D6AB415D428143D44749F57D720FC8FE7F@LTCFISWMSGMB21.FNFIS.com> <52655118.6010909@allanjude.com> <13CA24D6AB415D428143D44749F57D720FC90006@LTCFISWMSGMB21.FNFIS.com> <52656095.3070406@allanjude.com> <13CA24D6AB415D428143D44749F57D720FC90392@LTCFISWMSGMB21.FNFIS.com> <526561E1.3000903@allanjude.com> In-Reply-To: <526561E1.3000903@allanjude.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: yes X-MS-TNEF-Correlator: x-originating-ip: [10.132.253.120] Content-Type: multipart/signed; boundary="Apple-Mail=_D3543476-1BAB-41C2-9CC2-4516625BDB2C"; protocol="application/pgp-signature"; micalg=pgp-sha512 MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.10.8794, 1.0.431, 0.0.0000 definitions=2013-11-02_01:2013-11-02,2013-11-02,1970-01-01 signatures=0 Cc: Johan Broman , Devin Teske , "Teske, Devin" , " Current" X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Devin Teske List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Nov 2013 06:15:01 -0000 --Apple-Mail=_D3543476-1BAB-41C2-9CC2-4516625BDB2C Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" On Oct 21, 2013, at 10:18 AM, Allan Jude wrote: > On 2013-10-21 13:14, Teske, Devin wrote: >> On Oct 21, 2013, at 10:12 AM, Allan Jude wrote: >>=20 >>> On 2013-10-21 12:19, Teske, Devin wrote: >>>> On Oct 21, 2013, at 9:06 AM, Allan Jude wrote: >>>>=20 >>>>> On 2013-10-21 12:04, Teske, Devin wrote: >>>>>> On Oct 21, 2013, at 8:50 AM, Allan Jude wrote: >>>>>>=20 >>>>>>> On 2013-10-21 11:45, Johan Broman wrote: >>>>>>>> Hi! >>>>>>>>=20 >>>>>>>> Sorry for the delayed answer. I've patched zfsboot and rebuilt the >>>>>>>> release. I now get an error message that ada2 can't be used, which= is >>>>>>>> correct. Good stuff! :) >>>>>>>>=20 >>>>>>>> ( I've recreated the test environment using a KVM guest with four = SATA >>>>>>>> drives instead of the server I was using. I makes it easier to test >>>>>>>> stuff. ) >>>>>>>>=20 >>>>>>>> Here's the screenshot: >>>>>>>>=20 >>>>>>>> https://urldefense.proofpoint.com/v1/url?u=3Dhttp://212.181.212.14= 6/bsdinstall/Screenshot_2013-10-21.png&k=3D%2FbkpAUdJWZuiTILCq%2FFnQg%3D%3D= %0A&r=3DMrjs6vR4%2Faj2Ns9%2FssHJjg%3D%3D%0A&m=3DB6jLX5vSxIfvyks3HH55lYWtfhR= BpGZ3nVA65M%2FgmXM%3D%0A&s=3Df6fc4ec7c9d8b9486e897156dac5af7c3f64e3fae746dc= f6c66ad91564a8ce99 >>>>>>>>=20 >>>>>>>>=20 >>>>>>>> Maybe one should be unable to select drives that are part of a gra= id >>>>>>>> in the first place? Or is that out-of-scope for bsdinstall at this >>>>>>>> point? (As I guess that requires too many changes/new lines) >>>>>>>>=20 >>>>>>>>=20 >>>>>>>> Cheers >>>>>>>> Johan >>>>>>>>=20 >>>>>>>>=20 >>>>>>>> On 19/10/13 22:20, Teske, Devin wrote: >>>>>>>>> On Oct 19, 2013, at 10:07 AM, Johan Broman wrote: >>>>>>>>>=20 >>>>>>>>>> I recreated the graid mirror on ada2 and ada3 and reran the >>>>>>>>>> installation. I'm unable to scroll the msgbox using PgDn or arrow >>>>>>>>>> keys. There is no indication that the action failed and I'm retu= rned >>>>>>>>>> to the ZFS setup screen if I hit OK. >>>>>>>>>>=20 >>>>>>>>>> I have screen shots (taken with my phone) of the msgbox and "ps >>>>>>>>>> auxwww" output. Let me know what kind of debug info you would li= ke. >>>>>>>>>> I've put the screen shots here: >>>>>>>>>>=20 >>>>>>>>>> https://urldefense.proofpoint.com/v1/url?u=3Dhttp://212.181.212.= 146/bsdinstall&k=3D%2FbkpAUdJWZuiTILCq%2FFnQg%3D%3D%0A&r=3DMrjs6vR4%2Faj2Ns= 9%2FssHJjg%3D%3D%0A&m=3DB6jLX5vSxIfvyks3HH55lYWtfhRBpGZ3nVA65M%2FgmXM%3D%0A= &s=3D6322000e13ed155bda748698c4a0d54c9de7c29f5566affe202d7c5a29917cd1 >>>>>>>>> I've added a patch to fix debugging in the zfsboot script... >>>>>>>>>=20 >>>>>>>>> https://urldefense.proofpoint.com/v1/url?u=3Dhttp://druidbsd.cvs.= sf.net/viewvc/druidbsd/bsdinstall_zfs/&k=3D%2FbkpAUdJWZuiTILCq%2FFnQg%3D%3D= %0A&r=3DMrjs6vR4%2Faj2Ns9%2FssHJjg%3D%3D%0A&m=3DB6jLX5vSxIfvyks3HH55lYWtfhR= BpGZ3nVA65M%2FgmXM%3D%0A&s=3D1dc96a8b5450d27fe8210b361c9ed736ccd448f78df6aa= be170bb80e31bca6d9 >>>>>>>>>=20 >>>>>>>>> Feedback welcome. >>>>>>>>>=20 >>>>>>>>> Johan,... >>>>>>>>>=20 >>>>>>>>> Can you see if the patch sheds some better light as to what's fai= ling? >>>>>>>>>=20 >>>>>>>>> The patch won't fix the problem, but it should give us an accurat= e error >>>>>>>>> message so that we can learn what precisely is returning an error >>>>>>>>> status. >>>>>>>>>=20 >>>>>>>>> Thanks in advance. >>>>>>>>>=20 >>>>>>> I do notice that Devin's manually prefixing the error message with = the >>>>>>> tool name, is partially redundancy when the tool does it it self, b= ut we >>>>>>> can't always be sure it will do that. >>>>>>>=20 >>>>>> The next patchset will fix that. >>>>>>=20 >>>>>> I'm dropping the tool name from the msgbox contents and putting it in >>>>>> the title (e.g., '"Error: gpart") that way... even if the tool spits= out its own >>>>>> name (or not), we'll know what exactly what was going on by looking >>>>>> at the title. >>>>>>=20 >>>>>>=20 >>>>>>> the graid thing is rather hard to detect, especially when it is a >>>>>>> faulted array that doesn't even appear in graid status etc. >>>>>>>=20 >>>>>> I believe the idea behind the script is that whatever you tell it to= use will >>>>>> be destroyed. >>>>>>=20 >>>>>> Allan, maybe perhaps we could add some code that attempts to dis- >>>>>> assemble a graid to make the disk usable? >>>>>>=20 >>>>>> Johan, what would you be more apt to expect? That it killed your gra= id >>>>>> or that it gave an error? (/me thinks what the recourse to the error= might >>>>>> entail -- going to partedit?) >>>>> Your recourse would be switching to the shell (control+alt+f4) and >>>>> destroying the graid. >>>>>=20 >>>>> I am a little hesitant to go destroying graids unprompted. If we had = the >>>>> geom.confxml parsing, we might be able to detect it and ask the user >>>>> what to do >>>>>=20 >>>> Well, my concern with going and asking about each/every configuration >>>> before we clear it... >>>>=20 >>>> Hasn't the user already answered a "Last Chance!" dialog giving the go- >>>> ahead to nuke any/all data *and* configurations on a drive? >>> I guess that makes sense, We offer the dialog to allow the user to >>> investigate their disk in detail so they can be sure they picked the >>> correct ones. >>>=20 >>> the graid thing is the biggest gotcha because it picks up metadata >>> written by the motherboard raid system, so you can have a graid >>> configuration even if you have never booted freebsd before. >>>=20 >> Hmmm... so what does one do in *that* situation? >>=20 >> Go into the motherboard BIOS and disable on-board RAID features for >> the controller providing the disks-in-question? > You can destroy the metadata with the graid delete command. I've only > encountered once instance where 'graid status' didn't show any devices, > but graid was blocking zfs from using the device until the graid was > destroyed (the graid part was only discovered after generating an image > out of the geom.confdot sysctl) >=20 Allan, Do we want to add a "graid delete" command to the same place as the pedantic "gpart destroy" commands? --=20 Devin _____________ The information contained in this message is proprietary and/or confidentia= l. If you are not the intended recipient, please: (i) delete the message an= d all copies; (ii) do not disclose, distribute or use the message in any ma= nner; and (iii) notify the sender immediately. In addition, please be aware= that any message addressed to our domain is subject to archiving and revie= w by persons other than the intended recipient. Thank you. --Apple-Mail=_D3543476-1BAB-41C2-9CC2-4516625BDB2C Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="signature.asc" Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQEcBAEBCgAGBQJSdJhbAAoJEKrMn5R9npq5ldwIAKVzoAU6Sc0jwBK9zNamOuxx OWUZT4zB12FR/I9yDLBHVwRw+GF1rUMf0jM8SX0z1g0E47ehuqaxjUwmjoDMuhQY X3u9EwGwX8Dv67mcnek5Q926oXQTp9P+qMh2AcyGpdd9uOj+C+ebWhKGkm4/ccSh V2VwrgIRQDSIiLncLUuOHtQQikEKXPG2R9CJ1Tol2dU+gPpax1jl5hZsDsIf4DZ7 W8UpAhxaySgEHs/PhnDid4xUZ+1ofQD975Wd0x0N+5XfaLBArA5kEzCnCMxzFkFI YI74xY0aHN0ZT8pvOqFn+RuMry6/dN1xRJNcGp9WO8DVfRsvuLDufFCmmt0Vs9Q= =sZPZ -----END PGP SIGNATURE----- --Apple-Mail=_D3543476-1BAB-41C2-9CC2-4516625BDB2C--