Bug 2264795 - Workstation osbuild iso filesystems have incorrect filesystem label (says "BaseOS" not "Workstation")
Summary: Workstation osbuild iso filesystems have incorrect filesystem label (says "Ba...
Alias: None
Product: Fedora
Classification: Fedora
Component: osbuild
Version: 40
Hardware: Unspecified
OS: Linux
Target Milestone: ---
Assignee: Image Builder team
QA Contact: Fedora Extras Quality Assurance
Whiteboard: RejectedBlocker AcceptedFreezeException
Depends On:
Blocks: BetaFreezeException, F40BetaFreezeException 2233273
TreeView+ depends on / blocked
Reported: 2024-02-19 03:41 UTC by Dennis Gilmore
Modified: 2024-03-17 21:53 UTC (History)
13 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2024-03-17 21:53:34 UTC
Type: ---

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Github osbuild images issues 487 0 None open Fedora images have incorrect "BaseOS" in their ISO labels, fixing this is hard because of the templating design 2024-03-02 01:35:17 UTC

Description Dennis Gilmore 2024-02-19 03:41:54 UTC
Fedora-Workstation-Live-osb-40-20240218.n.0.aarch64.iso: ISO 9660 CD-ROM filesystem data 'Fedora-39-BaseOS-aarch64' (bootable)

It should identify itself as Fedora-40-Workstation-aarch64

Reproducible: Always

Comment 1 Adam Williamson 2024-02-19 16:16:49 UTC
that's the osbuild image, which is not the release-blocking image, it's an experimental image as part of https://fedoraproject.org/wiki/Changes/FedoraWorkstationImageBuilder - "The aim of this change is to create an additional, non-blocking Fedora Workstation live ISO using Image Builder." So I don't think it can be release blocking.

Comment 2 Dennis Gilmore 2024-02-19 18:59:42 UTC
It is the only AArch64 LiveCD iso available. but outside of that in grub it also identifies itself as Fedora 39

Comment 3 Adam Williamson 2024-02-19 19:44:32 UTC
well, yes, because build of the other one fails (due to the other bug you reported). but neither of them is release-blocking. the only Workstation ARM deliverable that's blocking is the raw disk image.

we can always discuss changing the blocking deliverable set, of course, but that's the current status. the current set was decided in the last round of discussing this with the ARM SIG, IIRC around when we dropped 32-bit support. the rationale I believe was that there wasn't a lot of hardware where using a generic installer ISO would be the 'most normal' way to deploy, it was considered that the raw disk image would be the 'normal' way to deploy on pretty much any supported hardware.

Comment 4 Geoffrey Marr 2024-02-20 05:34:47 UTC
Discussed during the 2024-02-19 blocker review meeting: [0]

The decision to classify this bug as a "RejectedBlocker (Beta)" and an "AcceptedFreezeException (Beta)" was made as it concerns an image which is not release-blocking. However, it's accepted as FE on the general principle we accept this kind of issue in non-blocking images as FE instead, but we will only land a fix that could not endanger blocking images.

[0] https://meetbot.fedoraproject.org/blocker-review_matrix_fedoraproject-org/2024-02-19/f40-blocker-review.2024-02-19-17.00.log.txt

Comment 5 Lukas Ruzicka 2024-02-20 10:54:56 UTC
This is the same case on x86_64 20240219 iso. When I boot into Grub, it says "Install Fedora 39".

Comment 6 Adam Williamson 2024-02-20 16:22:22 UTC
To be clear, you mean on the x86_64 *osbuild* ISO, right?

Comment 7 Adam Williamson 2024-02-20 17:38:43 UTC
So, hum, the cause of this might be pretty simple: the fedora-40 branch of fedora.conf still has this line in the osbuild section:

            'distro': 'fedora-39',

we, uh, probably need to change that.

Comment 8 Adam Williamson 2024-02-20 18:50:40 UTC
well, it's sort of simple, but sort of not. I was going to write a PR to change that to fedora-40 in pungi-fedora f40 branch and fedora-41 in pungi-fedora main branch, then I got the bright idea "huh, I guess I should check that osbuild knows about fedora-40 and fedora-41 first". Well, it seems to know about Fedora 40, but not Fedora 41, and there seem to be...uh...quite a lot of places that might need changing:

[adamw@xps13a local]$ grep -R "fedora-40" osbuild*
osbuild/.gitlab-ci.yml:          - aws/fedora-40-x86_64
osbuild/.gitlab-ci.yml:          - aws/fedora-40-aarch64
osbuild/Schutzfile:  "fedora-40": {
osbuild/test/data/stages/rpm/diff.json:    "/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-40-aarch64",
osbuild/test/data/stages/rpm/diff.json:    "/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-40-ppc64le",
osbuild/test/data/stages/rpm/diff.json:    "/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-40-primary",
osbuild/test/data/stages/rpm/diff.json:    "/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-40-s390x",
osbuild/test/data/stages/rpm/diff.json:    "/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-40-x86_64",
grep: osbuild-composer/.git/index: binary file matches
osbuild-composer/.gitlab-ci.yml:          - aws/fedora-40-x86_64
osbuild-composer/.gitlab-ci.yml:          - aws/fedora-40-aarch64
osbuild-composer/.gitlab-ci.yml:          - aws/fedora-40-x86_64
osbuild-composer/.gitlab-ci.yml:          - aws/fedora-40-aarch64
osbuild-composer/Schutzfile:  "fedora-40": {
osbuild-composer/repositories/fedora-40.json:      "metalink": "https://mirrors.fedoraproject.org/metalink?repo=fedora-40&arch=x86_64",
osbuild-composer/repositories/fedora-40.json:      "metalink": "https://mirrors.fedoraproject.org/metalink?repo=fedora-40&arch=aarch64",
osbuild-composer/repositories/fedora-40.json:      "metalink": "https://mirrors.fedoraproject.org/metalink?repo=fedora-40&arch=ppc64le",
osbuild-composer/repositories/fedora-40.json:      "metalink": "https://mirrors.fedoraproject.org/metalink?repo=fedora-40&arch=s390x",
grep: osbuild-image-builder/.git/index: binary file matches
osbuild-image-builder/distributions/fedora-40/fedora-40.json:    "name": "fedora-40",
osbuild-image-builder/distributions/fedora-40/fedora-40.json:        "metalink": "https://mirrors.fedoraproject.org/metalink?repo=fedora-40&arch=x86_64",
osbuild-image-builder/distributions/fedora-40/fedora-40.json:        "metalink": "https://mirrors.fedoraproject.org/metalink?repo=fedora-40&arch=aarch64",
osbuild-image-builder/internal/distribution/distroregistry_test.go:	allDistros := []string{"rhel-8", "rhel-8-nightly", "rhel-84", "rhel-85", "rhel-86", "rhel-87", "rhel-88", "rhel-89", "rhel-9", "rhel-9-nightly", "rhel-90", "rhel-91", "rhel-92", "rhel-93", "centos-8", "centos-9", "fedora-37", "fedora-38", "fedora-39", "fedora-40", "fedora-41"}
osbuild-image-builder/internal/distribution/distroregistry_test.go:	notEntitledDistros := []string{"rhel-8-nightly", "rhel-9-nightly", "centos-8", "centos-9", "fedora-37", "fedora-38", "fedora-39", "fedora-40", "fedora-41"}
osbuild-image-builder/internal/v1/api.go:	Fedora40     Distributions = "fedora-40"
osbuild-image-builder/internal/v1/api.yaml:        - fedora-40
osbuild-image-builder/internal/v1/handler_test.go:		require.ElementsMatch(t, []string{"rhel-8", "rhel-8-nightly", "rhel-84", "rhel-85", "rhel-86", "rhel-87", "rhel-88", "rhel-89", "rhel-9", "rhel-9-nightly", "rhel-90", "rhel-91", "rhel-92", "rhel-93", "centos-8", "centos-9", "fedora-37", "fedora-38", "fedora-39", "fedora-40", "fedora-41"}, distros)
grep: osbuild-images/.git/index: binary file matches
osbuild-images/pkg/distro/fedora/distro_test.go:		name:   "fedora-40",
osbuild-images/pkg/distro/fedora/distro_test.go:		distro: fedora.DistroFactory("fedora-40"),
osbuild-images/test/config-map.json:      "fedora-40",

I sent https://github.com/osbuild/image-builder/pull/1043 for image-builder. *Possibly* that's the only one that really needs changing - I *think* all the others might only ultimately be used for tests. But it's not really clear. None of the developer guide docs really seems to touch on this, as best as I can tell.

Comment 9 Adam Williamson 2024-02-22 07:33:30 UTC
obudai said it should be fine to change pungi-fedora without any changes to osbuild, so we went ahead and did that. Let's see how this looks in the next compose.

Comment 10 Adam Williamson 2024-03-01 21:44:44 UTC
[adamw@xps13a nightlies]$ file Fedora-Workstation-Live-osb-40-20240301.n.0.x86_64.iso
Fedora-Workstation-Live-osb-40-20240301.n.0.x86_64.iso: ISO 9660 CD-ROM filesystem data (DOS/MBR boot sector) 'Fedora-40-BaseOS-x86_64' (bootable)

looks fixed to me!

Comment 11 Adam Williamson 2024-03-01 23:18:54 UTC
Re-opening because the "BaseOS" bit isn't fixed yet.

Comment 12 Adam Williamson 2024-03-02 00:24:17 UTC
Digging into it a bit, this is seems to be hardcoded at https://github.com/osbuild/images/blob/629a002f34a342fcf835ed6c56497bb6c29851a2/pkg/distro/fedora/distro.go#L420 . It really shouldn't be. Nothing in Fedora is called BaseOS. :P

That string is used as a template - the "%s" remains, that's why it's double-%ed - and is then substituted here: https://github.com/osbuild/images/blob/629a002f34a342fcf835ed6c56497bb6c29851a2/pkg/image/anaconda_live_installer.go#L70

Fixing this is just *weirdly* hard for...reasons.

The obvious thing to do is make isolabelTmpl be `fmt.Sprintf("Fedora-%d-%%s-%%s", version)` - so it has another thing to be substituted later - and then change anaconda_live_installer.go to do:

isoLabel := fmt.Sprintf(img.ISOLabelTempl, img.Variant, img.Platform.GetArch())

and set an appropriate Variant in `liveInstallerImage` in pkg/distro/fedora/images.go (holding our nose and ignoring the fact that it's hardcoded to be Workstation when it *really* shouldn't be). But...that won't really work, because this thing is way more generic than that. The image definitions for fedora, rhel8 and rhel9 assign the distro template ('d.isolabelTmpl') to be a template for the image called 'img.ISOLabelTempl' for several different image types - not just the "AnacondaLiveInstaller" image type from anaconda_live_installer.go , but AnacondaContainerInstaller , AnacondaOSTreeInstaller , AnacondaTarInstaller and OSTreeSimplifiedInstaller . As mentioned, these are used by both Fedora and RHEL, and so far, they all expect to have an 'ISOLabelTempl' with only one substitution slot, for the image arch. If we change Fedora's distro template to have two substitution slots, we'd have to update all of those types (or at least all the ones Fedora uses) to expect two substitution slots, and define a variant for all the Fedora images that use any of those types - but we'd also then have to change the *RHEL* distro template to have two slots and set a variant for all the *RHEL* images as well, because the templates have to stay consistent. We can't have a template for Fedora with two slots but a template for RHEL with one slot. (Well, I guess we could, but we'd have to have some really ugly conditionals).

I kinda hate this design and don't want fixing it to be my problem, so I'm gonna write all of this up in an issue and dump it on the osbuild devs. I think maybe the solution is gonna have to be callbacks, but I don't really know Go and I don't want to spend my Friday evening discovering how to set this up in Go.

Comment 13 Adam Williamson 2024-03-17 21:53:34 UTC
OK, this got fixed by https://github.com/osbuild/images/pull/488 :

[adamw@xps13a mutter (main %)]$ file /share/data/isos/40/Beta/1.7/Fedora-Workstation-Live-osb-40_Beta-1.7.x86_64.iso 
/share/data/isos/40/Beta/1.7/Fedora-Workstation-Live-osb-40_Beta-1.7.x86_64.iso: ISO 9660 CD-ROM filesystem data (DOS/MBR boot sector) 'Fedora-40-Workstation-x86_64' (bootable)

the label still isn't as 'detailed' as the livemedia-creator ones, but at least it's not flat-out wrong.

Note You need to log in before you can comment on or make changes to this bug.