[ipxe-devel] dhcp user-class check for "iPXE"

Hummel Frank F.Hummel at ads-tec.de
Wed May 31 12:55:21 UTC 2017


Sorry, seems I have to revert that "working snippet" below which worked for version F0E9E (02/2016)
I tried to update to the latest version 356F today.	
It seems there were changes in dhcp.c which lead to a broken DHCP option user-class.
That "iPXE" condition is not met any more. 
This leads to the infinite boot loop Linto described.
Tried with today's git clone master.

DHCP_USER_CLASS_ID, DHCP_STRING ( 'i', 'P', 'X', 'E' ) is still present, but there is a new sequence below which doesn't seem to work in UEFI mode: 

/** Settings copied in to all DHCP requests */
static const struct setting * dhcp_request_settings[] = {
	&user_class_setting,
	&vendor_class_setting,
};

mit freundlichen Grüßen
with kind regards

i. A. Dipl.Ing. (FH) Frank Hummel
Systementwicklung
System development

ads-tec GmbH
Heinrich-Hertz Str. 1
72622 Nürtingen
Germany

Tel.:    +49 7022 2522-2412
Fax:    +49 7022 2522-400
E-Mail: F.Hummel at ads-tec.de
Web: www.ads-tec.de

-----Ursprüngliche Nachricht-----
Von: ipxe-devel-bounces at lists.ipxe.org [mailto:ipxe-devel-bounces at lists.ipxe.org] Im Auftrag von Hummel Frank
Gesendet: Freitag, 21. April 2017 08:42
An: Christian Nilsson; Linto Paul
Cc: iPXE
Betreff: Re: [ipxe-devel] dhcp user-class check for "iPXE"

Code snippet of my working dhcpd.conf:
-----------------------------
# UEFI Bios x64
		 if option arch = 00:07 {
				if exists user-class {
				if option user-class = "iPXE" {
					filename "/ipxe/efi/bootefi.ipxe";
# IPXE menu file loaded after second DHCP request while ipxe is up and running
								}
						    }
		filename "/ipxe/efi/ipxe.efi"; 
# UEFI ipxe boot file after first DHCP request
				        }
-----------------------------


mit freundlichen Grüßen
with kind regards

i. A. Dipl.Ing. (FH) Frank Hummel
Systementwicklung
System development

ads-tec GmbH
Heinrich-Hertz Str. 1
72622 Nürtingen
Germany

Tel.:    +49 7022 2522-2412
Fax:    +49 7022 2522-400
E-Mail: F.Hummel at ads-tec.de
Web: www.ads-tec.de

-----Ursprüngliche Nachricht-----
Von: ipxe-devel-bounces at lists.ipxe.org [mailto:ipxe-devel-bounces at lists.ipxe.org] Im Auftrag von Christian Nilsson
Gesendet: Donnerstag, 20. April 2017 19:19
An: Linto Paul
Cc: iPXE
Betreff: Re: [ipxe-devel] dhcp user-class check for "iPXE"

So you are sure it's the if statement that is never is hit, and not that filename is set again after that filename inside the if?
Just as a test, remove all other filename definitions and check what you get.

Also double check with tcpdump that everything is as you expected.
Could you post your full dhcpd.conf so we can check it?

On Thu, Apr 20, 2017 at 3:18 PM, Linto Paul <lintopaul at gmail.com> wrote:
> Hi Christian,
>
> Yes I have tried different filename options later in my dhcp.conf for 
> fallback such as ipxe.efi or undionly.kpxe but the issue is that the 
> former condition for user-class "iPXE" is never met and always go the 
> fallback filename specified.
>
> I've tried the Robin's example s already and also followed the ipxe 
> forum but couldn't get it working yet.
>
> Best regards,
> Linto
>
>
> On 20-Apr-2017 6:08 PM, "Christian Nilsson" <nikize at gmail.com> wrote:
>
> Hi!
>
> Do you happen to have any filename set later in your dhcpd.conf ?
>
> I tend to refer to Robins extensive example at
> https://gist.github.com/robinsmidsrod/4008017 see ipxe-green.conf for 
> ideas
>
> Other then that I would start checking with tcpdump for exactly what 
> is sent both ways.
>
> You can find several threads at
> http://forum.ipxe.org/forumdisplay.php?fid=2 about RHEL and UEFI.
> (If you want to post in the forum, remember that it is moderated for 
> new users, so won't be visible until a moderator have approved the
> post)
>
> /Christian
>
> On Thu, Apr 20, 2017 at 2:27 PM, Linto Paul <lintopaul at gmail.com> wrote:
>> Hello Folks,
>>
>> I am trying to iPXE boot latest RHEL 7.3 on HP Proliant Gen 9
>> server(XL190R)
>> in UEFI mode but can't get the infinite dhcp loop to be broken using 
>> the chain load option below:
>>
>> if exists user-class and option user-class = "iPXE"{
>>     filename "xx.xx.xx.xx/default.ipxe }
>>
>> No matter what I try this condition is never met so always the 
>> control goes to the else condition and tries to boot off the 
>> bootloader provided there.
>>
>> By the way, I am aware of using the ipxe compile option with embedded 
>> script to break from the loop but wasn't able to get it to boot as I 
>> get a kernel panic.
>>
>> Any help on getting around this dhcp option would be much appreciated.
>> Also,
>> any pointers on successful use cases with RHEL in UEFI mode would be 
>> helpful as well. From my understanding only RHEL 7.3 onwards can be 
>> used with iPXE in UEFI mode but correct me if I am wrong.
>>
>> Best regards,
>>
>> Linto
>>
>> _______________________________________________
>> ipxe-devel mailing list
>> ipxe-devel at lists.ipxe.org
>> https://lists.ipxe.org/mailman/listinfo.cgi/ipxe-devel
>>
>
>
_______________________________________________
ipxe-devel mailing list
ipxe-devel at lists.ipxe.org
https://lists.ipxe.org/mailman/listinfo.cgi/ipxe-devel
_______________________________________________
ads-tec GmbH
Sitz: 72622 Nürtingen
Registergericht Stuttgart HRB 224527

Geschaeftsfuehrer:
Dipl.-Ing. Thomas Speidel
_______________________________________________
Diese E-Mail enthaelt vertrauliche und/oder rechtlich
geschuetzte Informationen. Wenn Sie nicht der richtige
Adressat sind oder diese E-Mail irrtuemlich erhalten
haben, informieren Sie bitte sofort den Absender und 
vernichten Sie diese E-Mail. Das unerlaubte Kopieren,
jegliche anderweitige Verwendung sowie die unbefugte
Weitergabe dieser Mail sind nicht gestattet.
_______________________________________________

This e-mail may contain confidential and/or privileged
information. If you are not the intended recipient (or have
received this e-mail in error) please notify the sender
immediately and destroy this e-mail. Any unauthorized
copying, disclosure, distribution or other use of the
material or parts thereof are strictly forbidden.
_______________________________________________

_______________________________________________
ipxe-devel mailing list
ipxe-devel at lists.ipxe.org
https://lists.ipxe.org/mailman/listinfo.cgi/ipxe-devel
_______________________________________________
ads-tec GmbH
Sitz: 72622 Nürtingen
Registergericht Stuttgart HRB 224527

Geschaeftsfuehrer:
Dipl.-Ing. Thomas Speidel
_______________________________________________
Diese E-Mail enthaelt vertrauliche und/oder rechtlich
geschuetzte Informationen. Wenn Sie nicht der richtige
Adressat sind oder diese E-Mail irrtuemlich erhalten
haben, informieren Sie bitte sofort den Absender und 
vernichten Sie diese E-Mail. Das unerlaubte Kopieren,
jegliche anderweitige Verwendung sowie die unbefugte
Weitergabe dieser Mail sind nicht gestattet.
_______________________________________________

This e-mail may contain confidential and/or privileged
information. If you are not the intended recipient (or have
received this e-mail in error) please notify the sender
immediately and destroy this e-mail. Any unauthorized
copying, disclosure, distribution or other use of the
material or parts thereof are strictly forbidden.
_______________________________________________




More information about the ipxe-devel mailing list