Bug 2075358

Summary: Request for UEFI Kickstart Provisioning to handle naming convention for VLAN tagged interfaces of the format <parent_device>.<vlan_id> in addition to vlan<vlan_id>
Product: Red Hat Satellite Reporter: jalviso <jalviso>
Component: Provisioning TemplatesAssignee: Alexey Masolov <amasolov>
Status: CLOSED CURRENTRELEASE QA Contact: Gaurav Talreja <gtalreja>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.9.0CC: ahumbe, amasolov, dsinglet, ehelms, gtalreja, lstejska, mhulan, osousa, rlavi, saydas, sganar, shwsingh
Target Milestone: 6.15.0Keywords: Documentation, Triaged
Target Release: Unused   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: foreman-3.9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 2257321 (view as bug list) Environment:
Last Closed: 2024-05-13 13:13:38 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 jalviso 2022-04-14 00:49:02 UTC
Description of problem:

UEFI kickstart provisioning using Satellite through VLAN tagged interfaces can only handle vlan<vlan_id>. 

From the documentation:
https://access.redhat.com/documentation/en-us/red_hat_satellite/6.9/html/managing_hosts/adding_network_interfaces#adding-a-virtual-interface

Procedure 5:

"If creating a VLAN, specify ID in the form of eth1.10 in the Device Identifier field. If creating an alias, use ID in the form of eth1:10."

This works when provisioning host with legacy BIOS but not with EFI. 

Version-Release number of selected component (if applicable): 6.8 and above

How reproducible:

Steps to Reproduce:
1. Kickstart a physical host using a static address from a vlan tagged interface. 
   Navigate to Hosts -> All Hosts -> Select host -> Edit
   Under Interfaces tab, edit the virtual interface and name Device Identifier eth0.123, check Virtual NIC then Attach to: eth0

2. Download Full host boot disk image and boot host from this boot disk.

Actual results:

vlan123 at eth0 interface remains down and has no ip attached. The link itself has come up but the tagged vlan interface remains down. 

Test example, in the PXEGrub2 entry, it looks like this:

~~~
linux boot/redhat-7-9-rxAfaGWXYZo7-vmlinuz ks=http://test1.example.com:8000/unattended/provision?token=1e3ce613-7c3f-4fff-b833-50e2895adc03\&static=yes  noipv6 net.ifnames=0 biosdevname=0 rd.bootif=0 network ksdevice=eth0.123 ks.device=eth0.123 BOOTIF=01-0c-c4-7a-8e-4e-a0 kssendmac ks.sendmac inst.ks.sendmac ip=10.73.112.104::10.73.112.65:255.255.255.192:test1.example.com:eth0.123:none nameserver=10.10.10.1 vlan=vlan123:eth0 initrd boot/redhat-7-9-rxAfaGWXYZo7-initrd.img
~~~

Expected results:

At boot time, vlan123 virtual interface should be up.

Additional info:

Updating GRUB2 replacing eth0.123:none with vlan123:none in the parameter "ip="
brings up the interface but boot disk still fails. Editing "Virtual Interface" in Interfaces tab and change "Device Identifier" from eth0.123 to vlan123 (with Virtual NIC Attach to: eth0)
then download Full Host boot disk image and boot works.

Below are known affected provisioning templates (Note: I haven't checked the others) that supports only vlan<vlan_id>. Please add the naming convention <parent_device>.<vlan_id> to work on these template 
when provisioning UEFI:

Kickstart default
Kickstart default PXEGrub2
kickstart_kernel_options
kickstart_ifcfg_generic_interface

Comment 3 Bryan Kearney 2023-09-19 12:02:02 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/36361 has been resolved.

Comment 7 Gaurav Talreja 2023-11-22 14:00:30 UTC
Verified.

Tested on Satellite Stream Snap 38.0 
Version: foreman-3.9.0-0.5.develop.20231115163837git2774da2.el8sat.noarch

Steps:
1. Create host with interface as virtual NIC with device identifier, tag and attched_to.

Observation:
PXE templates now renders VLAN parameter as "vlan=<parent_device>.<tag>:<parent_device>" for tagged interfaces and provision/kickstart_default templates renders it as  "--interfacename=vlan<vlan_id>" same as previously.