Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 19 Oct 2013 17:28:09 +0000
From:      "Teske, Devin" <Devin.Teske@fisglobal.com>
To:        Allan Jude <freebsd@allanjude.com>
Cc:        "<freebsd-current@freebsd.org> Current" <freebsd-current@freebsd.org>, Thomas Dickey <dickey@radix.net>, "Teske, Devin" <Devin.Teske@fisglobal.com>
Subject:   Re: [CFT] Patch to bsdinstall to support root-on-ZFS and GELI
Message-ID:  <13CA24D6AB415D428143D44749F57D720FC7F01D@LTCFISWMSGMB21.FNFIS.com>
In-Reply-To: <5262B304.3090605@allanjude.com>
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>

next in thread | previous in thread | raw e-mail | index | archive | help

On Oct 19, 2013, at 9:27 AM, Allan Jude wrote:

> On 2013-10-19 11:55, Teske, Devin wrote:
>> On Oct 19, 2013, at 8:43 AM, Teske, Devin wrote:
>>=20
>>> On Oct 19, 2013, at 8:34 AM, Allan Jude wrote:
>>>=20
>>>> On 2013-10-19 11:31, Johan Broman wrote:
>>>>>=20
>>>>> On 19/10/13 17:23, Allan Jude wrote:
>>>>>> On 2013-10-19 10:56, Johan Broman wrote:
>>>>>>> Hi!
>>>>>>>=20
>>>>>>> Just tested the root-on-ZFS install option using FreeBSD 10 beta 1.=
 I
>>>>>>> have 4 SATA drives in my server. I select all four of them in a RAI=
DZ1
>>>>>>> setup. I hit enter to continue the installation and the zpool is
>>>>>>> created, but I'm then returned to the zpool selection screen again.=
 It
>>>>>>> turned out that two of the drives had previously been used in a
>>>>>>> (Linux) software mirror setup and because of this they got activated
>>>>>>> in /dev/raid/r0. Because of this I ended up in an endless bsdinstall
>>>>>>> loop.
>>>>>>>=20
>>>>>>> Removing the raid device using the graid command resolved the
>>>>>>> situation.
>>>>>>>=20
>>>>>>> Now maybe this is working as designed, but there was no warning/ale=
rt
>>>>>>> to the fact that the devices couldn't be used. Perhaps a warning
>>>>>>> should be rasied in this situation?
>>>>>>>=20
>>>>>>> Thanks for all the great work on the new installer, really looking
>>>>>>> forward to FreeBSD 10!
>>>>>>>=20
>>>>>>> Cheers
>>>>>>> Johan
>>>>>>> _______________________________________________
>>>>>>> freebsd-current@freebsd.org mailing list
>>>>>>> https://urldefense.proofpoint.com/v1/url?u=3Dhttp://lists.freebsd.o=
rg/mailman/listinfo/freebsd-current&k=3D%2FbkpAUdJWZuiTILCq%2FFnQg%3D%3D%0A=
&r=3DLTzUWWrRnz2iN3PtHDubWRSAh9itVJ%2BMUcNBCQ4tyeo%3D%0A&m=3DAnourZYCpeybP9=
aMxTFH%2B4GBOf0xikQ2jpEi%2BPFWcKo%3D%0A&s=3Dfec708d91fa0976a0e297ef36288511=
68f36e9cb34727dc7935e26ae190e90da
>>>>>>> To unsubscribe, send any mail to
>>>>>>> "freebsd-current-unsubscribe@freebsd.org"
>>>>>> Errors like that normally generate a msgbox dialog with the error ou=
tput
>>>>>> from whichever command failed. I'll have to dig into it and see where
>>>>>> that problem is. I've seen other people have problems creating ZFS
>>>>>> arrays after graid, but in that case it was an incomplete graid label
>>>>>> causing a device to be locked but not appear in the graid status out=
put.
>>>>>>=20
>>>>> Ah ok. A msgbox did appear but the drives that had the problem (ada2
>>>>> and ada3) wasn't visible in the output. (not sure if the box itself
>>>>> has a size limit or maybe I was just unable to scroll down and see the
>>>>> errors?). The only visible output was that it was able to create
>>>>> labels on ada0 and ada1.
>>>>>=20
>>>>> /Johan
>>>>> _______________________________________________
>>>>> freebsd-current@freebsd.org mailing list
>>>>> https://urldefense.proofpoint.com/v1/url?u=3Dhttp://lists.freebsd.org=
/mailman/listinfo/freebsd-current&k=3D%2FbkpAUdJWZuiTILCq%2FFnQg%3D%3D%0A&r=
=3DLTzUWWrRnz2iN3PtHDubWRSAh9itVJ%2BMUcNBCQ4tyeo%3D%0A&m=3DAnourZYCpeybP9aM=
xTFH%2B4GBOf0xikQ2jpEi%2BPFWcKo%3D%0A&s=3Dfec708d91fa0976a0e297ef3628851168=
f36e9cb34727dc7935e26ae190e90da
>>>>> To unsubscribe, send any mail to
>>>>> "freebsd-current-unsubscribe@freebsd.org"
>>>> Ahh yes, you have to press 'page-down' to scroll the msgbox. I tried to
>>>> add a scrollbar but turns out that is not possible.
>>>>=20
>>>> The only indication that there is more message to read, is a small 'xx=
%'
>>>> in the bottom right. We might have to look at breaking that output up =
or
>>>> something.
>>>>=20
>>>=20
>>> The only reason for a msgbox widget to scroll is if it is displayed at
>>> maximum height or width of the screen and it *still* has more data
>>> to display than can be presented at-once.
>>>=20
>> I should clarify...
>>=20
>> The zfsboot script doesn't use dialog(1) directly. It uses the bsdconfig=
 API.
>> That being said, msgbox widgets automatically scale their size to fit the
>> content being displayed. So whenever a msgbox is thrown up using this
>> API... the widget will never scroll unless the box can't be made big eno=
ugh
>> to hold the entire content (either the screen resolution or terminal siz=
e is
>> too small; we maxed out the size of the widget; and there's still hidden
>> content).
>>=20
>> But...
>>=20
>> While all of bsdconfig uses this API, hardly any of bsdinstall uses this=
 API.
>>=20
>>=20
>>=20
>>> If... however... the msgbox widget is *not* full-height or full-width
>>> yet... it is requiring you to scroll -- then we've found a bug.
>>>=20
>>> Can we get a screen shot?
>> So we really need to nail down precisely which error box this is so that
>> we can address whether the issue is in-fact an instance of using the old
>> error-box handling instead of the auto-sizing API.
>>=20
>> So...
>>=20
>> With this described API, you should never have to scroll a box unless it
>> can't fit all the data *and* you should be able to immediately identify =
when
>> that becomes the case...
>>=20
>> 1. The widget spans the entire width of the screen.
>>=20
>> 2. The widget spans the entire height of the screen.
>>=20
>> 3. Both 1 and 2.
>>=20
>> It's in *those* cases that you should then *EXPECT* to find that the
>> region can scroll with cursor keys and page up/down (look for the
>> scroll percentage in the widget as Allan suggested.
>>=20
>> I don't want to see the scroll percentage doohickey *unless* the widget
>> is auto-sized to full-width or full-height. Meaning, there's either a bu=
g in
>> the API or someone fell into a trap (there are a couple).
>=20
> the error output msgbox is huge, probably 100+ lines (the screen is
> what, 24 lines high, and with the ok button, top and bottom reserved
> space etc, can display maybe 18 lines at once)
>=20

OK, so we're probably talking about the log file view on-errror.
Not the other big msgbox widget ... the disk info viewer. Both of
those I believe suffer from the same problem because they are
using the msgbox widget.


> It contains all the shell output from everything we do, creating the
> gparts, setting up gnop, all of the redundant destroys etc.
>=20

Ok, yes, then we're definitely talking about the log file viewer.



> I don't think the TINY little % in the bottom right is really enough of
> an indicator to the user that they CAN scroll, let alone HOW to scroll
> (IIRC the arrow keys do not work, must use page down)
>=20

The keybindigs for the msgbox indeed ignore up/down arrows.

However... I think we can overcome that by switching from the
msgbox widget to instead the textbox widget.

However... here's the problem...

Despite the fact that when you say "man dialog" and look at the
definition of textbox, and it has exactly every keybinding you'd
ever expect to find...

You can *only* use the textbox widget with a file.

Sad news... it doesn't support "-" as a file to read from stdin.
Worse news... attempts to use /dev/stdin as a hack have failed.

So for the log view on-error... we can just switch over to using
the f_dialog_textbox() API call and I'm sure everything will be
much better.

But for the disk info screen where we are programmatically
providing the input via code that generates a realtime message,
the textbox widget won't work for us (sad face).

I should write Thomas Dickey and ask him if he could add "-"
as a path to read from stdin (might require some buffering).
--=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.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?13CA24D6AB415D428143D44749F57D720FC7F01D>