Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support for handling RHEL9 hv node setup #482

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

radez
Copy link
Contributor

@radez radez commented May 2, 2024

I have not tested this with RHEL8 HVs yet.
I have deployed SNOs on RHEL9 HVs using this patch.

Copy link
Member

@akrzos akrzos left a comment

Choose a reason for hiding this comment

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

Thanks for getting the tires kicked on this @radez. Did you have time to test that we don't break rhel8 with these since rhel8 is still the default shipped in the lab?

ansible/roles/hv-install/tasks/main.yml Outdated Show resolved Hide resolved
@@ -4,6 +4,7 @@
- name: Clean lab interfaces
shell: |
/root/clean-interfaces.sh --nuke
ignore_errors: true
Copy link
Member

Choose a reason for hiding this comment

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

Does the rhel9 deployed OS not work with the clean-interfaces.sh script? Does it exist on the rhel9 Scale lab image/build?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It fails if the interfaces have already been cleaned.

Copy link
Member

Choose a reason for hiding this comment

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

Is that the intended behavior? Should we skip the clean interfaces for rhel9? We have to be very careful with the usage of ignore_errors when we can.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not sure, it's different on RHEL8 vs RHEL9. It seems to fail silently on 8 and not on 9. I'll see if I can compare again.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Looks like the clean interfaces script has been rewritten to use nmcli on RHEL9.

Copy link
Member

Choose a reason for hiding this comment

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

Got it so in that case it returns an error code that ansible now picks up whereas with rhel8, it would fail but no error code was emitted and therefore not picked up by ansible?

ansible/roles/hv-install/tasks/main.yml Outdated Show resolved Hide resolved
ansible/roles/hv-install/tasks/main.yml Outdated Show resolved Hide resolved
Copy link
Contributor Author

@radez radez left a comment

Choose a reason for hiding this comment

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

I have not yet run this patch with rhel8.

ansible/roles/hv-install/tasks/main.yml Outdated Show resolved Hide resolved
@@ -4,6 +4,7 @@
- name: Clean lab interfaces
shell: |
/root/clean-interfaces.sh --nuke
ignore_errors: true
Copy link
Contributor Author

Choose a reason for hiding this comment

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

It fails if the interfaces have already been cleaned.

@radez
Copy link
Contributor Author

radez commented May 21, 2024

I have tested this patch on both RHEL8 and RHEL9.
I think the only thing left to sort out is how to handle the clean_interfaces.sh differences.

Comment on lines +6 to +14
- name: RHEL version rhel9 check
set_fact:
hv_rhel_version: "rhel9"
when: ansible_facts['distribution_major_version'] is version('9', '==')

- name: RHEL version rhel8 check
set_fact:
hv_rhel_version: "rhel8"
when: ansible_facts['distribution_major_version'] is version('8', '==')
Copy link
Member

Choose a reason for hiding this comment

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

We don't need these two tasks anymore I believe.

@@ -112,7 +112,7 @@
<listen type='address' address='0.0.0.0'/>
</graphics>
<video>
<model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1' primary='yes'/>
<model type='vga' heads='1' primary='yes'/>
Copy link
Member

Choose a reason for hiding this comment

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

I won't pretend to know the differences between libvirt video model types, but did libvirt kick back an error with qxl instead of vga type when it was rhel9? Just curious for the change.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yup, rhel9 didn't like qxl but rhel8 didn't mind vga

@akrzos
Copy link
Member

akrzos commented May 28, 2024

Hey @radez curious if there is a method other than foreman re-provisioning to quickly move from RHEL8 to RHEL9 hypervisors as well as downgrade back? Is there a specific RHEL9 version 9.4? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants