-
jbk
hrm.. that's interesting..
-
jbk
tsoome: so if you run loader on a mirrored boot disk where the zfs partition isn't readable, it doesn't look for the other mirror..
-
jbk
you have to run loader from the other disk
-
AmyMalik
i believe i have experienced this problem a few times with freebsd; it's my understanding that illumos loader is based on freebsd's?
-
jbk
yes
-
jbk
unfortunately, I don't have time right now to dig further (another issue with $REALLY_BIG_CUSTOMER just came up), but I can probably dig a bit more once that's resolved
-
jbk
it would be nice once we can eventually ditch legacy bios support..
-
jbk
being able to assume UEFI would simplify a number of things a fair amount
-
danmcd
@tsoome Is jbk ^^^ correct that if we deprecate BIOS things could get Much Simpler?
-
jbk
there used to be something that'd basically implement UEFI over the BIOS settings (more or less)
-
jbk
in EDK-II
-
jbk
but it got removed after 8-10 years
-
jbk
(though could probably revive it from the commit history)
-
danmcd
My Haswell and Haswell-E Kebecloud nodes probably have UEFI over the BIOS settings. My HN and one netbooting CN use UEFI.
-
danmcd
To be fair IF we do something that crazy we'll need a LONG lead time.
-
tsoome
jbk loader should walk all DVA's
-
tsoome
the BIOS version does have 2 principal issues - one is limited API to access hardware - so people have written drivers for boot loaders (like one can find in grub), and second one is loader size limit due to how its laid out in memory. UEFI has quite rich API, but how much one can actually use is unknown due to bugs:D
-
jbk
tsoome: it would appear it's not walking all of the DVAs...
-
jbk
one 'crazy' thing I had thought about was taking the zfs code there and turning it into a UEFI filesystem driver
-
jbk
so you could do things like browse pools (read only) from the UEFI shell
-
jbk
(it could also be a piece of a solution where it'd allow the kernel to read from a zpool while booting (similar to sparc) to load drivers, /etc/path_to_inst, etc and not need a ramdisk (could still do that, but wouldn't be required)
-
tsoome
there was some work done in freebsd, boot1.efi was providing FS interface. However, that implies loading kernel with BS enabled (so you have no control over memory) while loading bits. Therefore i's a question about the architecture. AFAIK windows is doing something similar - first bits are loaded with help of UEFI and at some point when it has essential drivers loaded, the machine is taken over.
-
jbk
you have _some_ control.. though I think you have to coordinate with UEFI (at least until you exit boot services)
-
tsoome
yea you can give hints, but thats basically it.
-
tsoome
DVAs are walked in zio_read() in usr/src/boot/libsa/zfs/zfsimpl.c I think I did test it to verify, but I havent done it lately. probably good idea to recheck....
-
jbk
with it getting late, maybe tomorrow I can try to dig into it
-
jbk
basically the boot disks are a mirrored zpool, but on the one, the zfs partition was read/write locked
-
sommerfeld
jbk: out of curiosity, what's the underlying storage that has partition-level access controls like that?
-
AmyMalik
sleep well jbk
-
richlowe
I think maybe the disk is read-only, and not the partition? in the sentence
-
jbk
well it's more starting LBA-range
-
jbk
no, it's read and write
-
jbk
sommerfeld: TCG self encrypting drive
-
richlowe
oh
-
jbk
you can define (non-overlapping) LBA ranges that can be read and/or write locked
-
jbk
technically some of the standards (maybe pyrite? can't recall) don't include encryption and just the read/write protect, but opal, enterprise, opalite all will generate an AES key to encrypt the range when you define it
-
sommerfeld
jbk: ah, yeah, makes sense if you have to load the keys before you can meaningfully do i/o to the region .. raise the bar on accidentally whacking a slice.
-
jbk
the way the spec works, you actually have separate 'authorities' (think users) that you authenticate to the drive, and then manipulate the {read,write}locked setting.. the actual AES key shouldn't be able to be extracted from the drive
-
jbk
of course how a vendor implements it isn't really in the spec -- e.g. if they wrap the keys on the user's pins or not
-
jbk
or just 'if (user_has_permission) { allow_change_to_rw_state() }'
-
jbk
the whole spec is rather... uhm.. elaborate...
-
jbk
they define a reliable message based transport (including framing/reassembly) which AFAICT excactly 0 bits of hardware implement, instead opting for a much (much) simpler synchronous variant in the standard..
-
jbk
(i.e. you send one packet, your request must fit in 1 packet, and you then wait until you get exactly 1 response)
-
richlowe
is this one of those industry groups that produce weird overblown libraries?
-
richlowe
huh, no, that was SNIA apparently
-
richlowe
maybe still is
-
jbk
i don't know... there's no publicly available code I'm aware of, and we had to write our own
-
jbk
it's all a part of TCG
-
jbk
so a different subgroup(?) does the TPM standards
-
jbk
which does include a C API in the spec
-
jbk
(thought it's really not too bad -- they actually do a decent job with ABI versioning in the spec
-
jbk
the 'reference' Intel implementation of the libraries has a few non-standard bits (mostly assuming struct dirent includes file type in the code managing on-disk objects)
-
jbk
and probably uses autoconf and libtool more than it needs to... but that's far from the first project to do that...
-
jbk
which reminds me... I should probably go ahead and upstream my tpm2.0 driver
-
jbk
i had wanted to get the TABRM bits done, but not sure at this point when I'll be able to do that (without it, only one thing can have the device open at a time)
-
richlowe
there is to my knowledge 0 reason to use libtool
-
jbk
I agree...
-
jbk
there's also something with their autoconf bits... if you try to run them (from checking out master).. at least on omnios, it fails in a way that seems inscruitable (even for m4).. so you end up wanting to stick releases where configure, libtool, etc have all been generated and are in the tarball
-
richlowe
that used to often mean you were not using the version of auto* they were and something isn't compatible
-
richlowe
but it's been a long long time, thankfully
-
jbk
supposedly it's a compatible version
-
richlowe
these days the omnios folks usually already have whatever I need
-
richlowe
I dread having to engage with meson etc, more seriously
-
jbk
but I also wouldn't be surprised if it's 'well we never tested that version but thought it'd work'
-
jbk
since there's currently no tpm driver, I don't believe they've been building the tpm2 utilities
-
jbk
though I have a pkgtools branch so I can use it on smartos that I probably need to upstream to jperkin at some point (and omni could probably use the same patches)