Bug 2168967
Summary: | New kickstart_kernel_options snippet breaks UEFI (Grub2) PXE provisioning when boot_mode is static | |||
---|---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Joniel Pasqualetto <jpasqual> | |
Component: | Provisioning Templates | Assignee: | Joniel Pasqualetto <jpasqual> | |
Status: | CLOSED ERRATA | QA Contact: | sganar | |
Severity: | medium | Docs Contact: | ||
Priority: | high | |||
Version: | 6.12.1 | CC: | ahumbe, etiennedh, jbreitwe, lstejska, mhulan, osousa, pcreech, riehecky, risantam, sadas, saydas | |
Target Milestone: | 6.13.0 | Keywords: | Regression, Triaged | |
Target Release: | Unused | |||
Hardware: | Unspecified | |||
OS: | Unspecified | |||
Whiteboard: | ||||
Fixed In Version: | foreman-3.5.1.12-1 | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 2175005 (view as bug list) | Environment: | ||
Last Closed: | 2023-05-03 13:25:08 UTC | Type: | Bug | |
Regression: | --- | Mount Type: | --- | |
Documentation: | --- | CRM: | ||
Verified Versions: | Category: | --- | ||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
Cloudforms Team: | --- | Target Upstream Version: | ||
Embargoed: |
Description
Joniel Pasqualetto
2023-02-10 19:13:03 UTC
Workaround for customers running Satellite 6.12.2: Create a patch file named /root/kickstart_kernel_options_fix.patch with the following content: ~~~ --- original.erb 2023-02-10 15:16:54.429723695 -0500 +++ fix.erb 2023-02-10 15:18:37.722730201 -0500 @@ -39,19 +39,19 @@ # both current and legacy syntax provided if (is_fedora && os_major >= 33) || (rhel_compatible && os_major >= 9) if subnet4 && !subnet4.dhcp_boot_mode? - options.push("inst.ks=#{foreman_url('provision', static: '1')}") + options.push("inst.ks=#{foreman_url('provision', static: '1').gsub('&','\\\\&')}") elsif subnet6 && !subnet6.dhcp_boot_mode? - options.push("inst.ks=#{foreman_url('provision', static6: '1')}") + options.push("inst.ks=#{foreman_url('provision', static6: '1').gsub('&','\\\\&')}") else - options.push("inst.ks=#{foreman_url('provision')}", "inst.ks.sendmac") + options.push("inst.ks=#{foreman_url('provision').gsub('&','\\\\&')}", "inst.ks.sendmac") end else if subnet4 && !subnet4.dhcp_boot_mode? - options.push("ks=#{foreman_url('provision', static: '1')}") + options.push("ks=#{foreman_url('provision', static: '1').gsub('&','\\\\&')}") elsif subnet6 && !subnet6.dhcp_boot_mode? - options.push("ks=#{foreman_url('provision', static6: '1')}") + options.push("ks=#{foreman_url('provision', static6: '1').gsub('&','\\\\&')}") else - options.push("ks=#{foreman_url('provision')}", "kssendmac", "ks.sendmac") + options.push("ks=#{foreman_url('provision').gsub('&','\\\\&')}", "kssendmac", "ks.sendmac") end end ~~~ Run the following commands: TEMPLATE_ID=$(hammer template list --search name=kickstart_kernel_options --fields id |grep -v -e 'ID' -e '^-') cp /usr/share/foreman/app/views/unattended/provisioning_templates/snippet/kickstart_kernel_options.erb /root/kickstart_kernel_options_fix.erb patch -p1 /root/kickstart_kernel_options_fix.erb < /root/kickstart_kernel_options_fix.patch hammer template update --locked false --id $TEMPLATE_ID hammer template import --name kickstart_kernel_options --file /root/kickstart_kernel_options_fix.erb hammer template update --locked true --id $TEMPLATE_ID same problem here. need to force "BIOS mode" in VMware to start the VM Hello Have a look at comment #1 for a workaround: https://bugzilla.redhat.com/show_bug.cgi?id=2168967#c1 It was marked private, but I don't see a reason to keep it that way. If you're a Red Hat customer, you can also find the workaround here: https://access.redhat.com/solutions/6997923 Hi, in upstream PR [0] is suggested to use different approach, instead of escaping special chars just quote the URL. Could you please confirm the fix? [0] https://github.com/theforeman/foreman/pull/9582/files Hello While quoting would work for Grub2 and solve the problem described in this BZ, using a quoted URL would break BIOS provisioning which uses Grub. Escaping works in both scenarios and that's why I proposed escaping in my PR. *** Bug 2172545 has been marked as a duplicate of this bug. *** Moving to POST as PR is merged upstream. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Important: Satellite 6.13 Release), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2023:2097 *** Bug 2242913 has been marked as a duplicate of this bug. *** |