Page MenuHomeFreeBSD

Fix ESP generation when using a gmirror, and when booting from RO medium
ClosedPublic

Authored by bcran on Dec 24 2018, 2:41 AM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, May 19, 7:41 PM
Unknown Object (File)
Tue, May 19, 1:23 AM
Unknown Object (File)
Mon, May 18, 11:04 AM
Unknown Object (File)
Mon, May 18, 3:36 AM
Unknown Object (File)
Wed, Apr 29, 3:12 AM
Unknown Object (File)
Wed, Apr 29, 3:06 AM
Unknown Object (File)
Mon, Apr 27, 6:50 PM
Unknown Object (File)
Fri, Apr 24, 12:59 AM
Subscribers
None

Details

Summary

When using a gmirror, entries in /dev can be removed. So instead of using
kern.disks, get the list of disks from "gpart status -sg" instead.

We assume that any 'efi' partition that can't be mounted as msdosfs should
be used as an ESP. However, the ESP on the CD/DVD can't be mounted read-write
and so was being treated as if unformatted. Try the mount as read-only
instead, to catch cases like this.

Also, add some messages to let users know what the script is doing.

Relnotes: yes
Sponsored by: Netflix

Test Plan

Verified it works in a Qemu VM booting from dvd1.iso

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

I think this is fine, but I'm not totally sure.

This revision was not accepted when it landed; it landed in state Needs Review.Dec 31 2018, 12:21 AM
This revision was automatically updated to reflect the committed changes.