iPXE get custom dhcp option (option nisplus-domain string) - Printable Version +- iPXE discussion forum (https://forum.ipxe.org) +-- Forum: iPXE user forums (/forumdisplay.php?fid=1) +--- Forum: General (/forumdisplay.php?fid=2) +--- Thread: iPXE get custom dhcp option (option nisplus-domain string) (/showthread.php?tid=5437) |
iPXE get custom dhcp option (option nisplus-domain string) - Torgeir - 2012-09-17 14:19 Hi! Is it possible to get out a custom dhcp option "option nisplus-domain string" from within iPXE? Or easily done by adding to source and build from source? Dont know how all this is tied together... Regards, Torgeir RE: iPXE get custom dhcp option (option nisplus-domain string) - mcb30 - 2012-09-17 16:00 (2012-09-17 14:19)Torgeir Wrote: Is it possible to get out a custom dhcp option "option nisplus-domain string" from within iPXE? You should be able to access the NIS+ domain using: Code: echo ${64:string} You'll need to force your DHCP server to hand out this option even though iPXE doesn't request it. With ISC dhcpd, you can do this using something like: Code: append dhcp-parameter-request-list 64; in /etc/dhcpd.conf. Michael RE: iPXE get custom dhcp option (option nisplus-domain string) - Torgeir - 2012-09-17 16:11 Cool, thanks I know. Here we have used the NIS+ domain string for something that would be useful for us to get out in a iPXE boot environment. Torgeir RE: iPXE get custom dhcp option (option nisplus-domain string) - mcb30 - 2012-09-17 16:14 (2012-09-17 16:11)Torgeir Wrote: But here we have used the NIS+ string for something that would be cool to be able to get out in iPXE. I don't understand what you're saying, sorry. You can access the DHCP option via ${64:string}, and embed that in whatever command you like. If you want to use it as a web server address, for example, you can do something like Code: kernel http://${64:string}/boot.ipxe What are you trying to do with the NIS+ server option, and what is the problem you are having? Michael RE: iPXE get custom dhcp option (option nisplus-domain string) - Torgeir - 2012-09-17 16:39 It worked! Added to (dhcpd.conf) append dhcp-parameter-request-list 64; inside my scope option nisplus-domain "somehing_useful"; Torgeir (2012-09-17 16:14)mcb30 Wrote:(2012-09-17 16:11)Torgeir Wrote: But here we have used the NIS+ string for something that would be cool to be able to get out in iPXE. Sorry! I was unclear. We have a string inside the "option nisplus-domain string" that we want to add to our kickstart installer (as boot argument). So we can pick it up with cat /proc/cmdline, and then use that information by our post/pre kickstart scripts. Torgeir |