Bug 278480 - Standardize GPT label names
Summary: Standardize GPT label names
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-04-20 11:54 UTC by Jose Luis Duran
Modified: 2024-04-24 13:56 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jose Luis Duran 2024-04-20 11:54:14 UTC
Inspired by poudriere's pull request:

https://github.com/freebsd/poudriere/pull/1143

I submitted https://github.com/freebsd/freebsd-src/pull/1187 to keep things similar.

It is a little annoying that depending on the image created the final GPT label for the EFI partition has a different name.

Thus, if you want to add an entry in /etc/fstab using this label, you'll end up having different configurations. For example:

bsdinstall (zfsboot):
/dev/gpt/efiboot0	/boot/efi		msdosfs	rw		2 2

vmimage:
/dev/gpt/efiesp		/boot/efi		msdosfs	rw		2 2

nanobsd/poudriere firmware:
/dev/gpt/efiboot	/boot/efi		msdosfs	rw		2 2


I personally prefer "efiboot$index", but any name will do, as long as they are all the same.
Comment 1 Warner Losh freebsd_committer freebsd_triage 2024-04-21 04:14:37 UTC
Hmmm, maybe we should get poudriere and nanobsd to use efiboot0 and then change vmimage?
Comment 2 commit-hook freebsd_committer freebsd_triage 2024-04-23 21:43:36 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/src/commit/?id=4f223e0da7b4a055d9416f9161b44ffed765a9c3

commit 4f223e0da7b4a055d9416f9161b44ffed765a9c3
Author:     Jose Luis Duran <jlduran@gmail.com>
AuthorDate: 2024-04-23 21:12:30 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2024-04-23 21:13:40 +0000

    release: Change vmimage EFI GPT label

    This matches the default bsdinstall nomenclature.

    PR: 278480
    Reviewed by: imp
    Pull Request: https://github.com/freebsd/freebsd-src/pull/1188

 release/tools/vmimage.subr | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Comment 3 commit-hook freebsd_committer freebsd_triage 2024-04-23 21:43:37 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/src/commit/?id=14e3f2d8d3eb6f47556e59bee3e2004ac9a9d7e6

commit 14e3f2d8d3eb6f47556e59bee3e2004ac9a9d7e6
Author:     Jose Luis Duran <jlduran@gmail.com>
AuthorDate: 2024-04-23 21:12:45 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2024-04-23 21:13:35 +0000

    nanobsd: Set a GPT label for EFI and cfg partitions

    Use efiboot0 for the EFI partition, the nomenclature efiboot + #index
    was taken from bsdinstall (zfsboot).

    Use cfg for the cfg partition.  Poudriere firmware images are already
    using this label.

    PR: 278480
    Reviewed by: imp
    Pull Request: https://github.com/freebsd/freebsd-src/pull/1187

 tools/tools/nanobsd/embedded/common | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Comment 4 Jose Luis Duran 2024-04-24 13:56:09 UTC
There's still arm.subr, I have a work-in-progress here:

https://github.com/jlduran/freebsd-src/pull/68

But I have to test it first.

The main issue has been addressed, so this problem report can be closed. Thank you!