Skip to content

Conversation

lbajolet-hashicorp
Copy link
Contributor

As discussed in the RHEL9 panic issue linked to this PR, this PR is an attempt to make it easier for users of Packer/qemu on RHEL9+ hosts to set the CPU model for their builds.

Since qemu64 (the default value) is not supported anymore on such hosts, we add this option to make it easier for those users to set a supported value. This also gives us a good opportunity to document the kind of workaround necessary to make a build work in such an environment.

When the value is not set, the option is not automatically added (we can maybe discuss this part, @nywilken, what do you think?).

Closes: #76

The CPU model is a qemu setting that lets users change the default cpu
model used for building their VM image.

On some Linux distributions (RHEL9), the default value for x86-64 hosts
and guests (qemu64) is unsupported, leading to the plugin failing to
start a VM.

To make it easier for these users to user Packer with qemu, we add this
option to the configurations, so they can specify it.

This also allows us to document the potential problem they will
encounter, and suggest a workaround if/when it arises.
@lbajolet-hashicorp lbajolet-hashicorp requested a review from a team as a code owner January 6, 2023 22:04
@lbajolet-hashicorp lbajolet-hashicorp changed the title Cpu model option CPU model option Jan 6, 2023
Copy link

@sylviamoss sylviamoss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏼 LGTM! Makes sense to me keeping the default empty, which is the current exiting behavior.

@lbajolet-hashicorp lbajolet-hashicorp merged commit 8ad4058 into main Jan 24, 2023
@lbajolet-hashicorp lbajolet-hashicorp deleted the cpu_model_option branch January 24, 2023 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RHEL 9 kernel panic on Packer launched qemu-kvm
2 participants