Hi, On Sat, Oct 17, 2009 at 4:42 AM, Pavel Pisa <p...@cmp.felk.cvut.cz> wrote: > As for scalability, I agree, that use of single config file with checking > for each IP is horrible hack, but there is no problem to source > to another IP specific file (menu-xxx.xxx.xxx.xxx.lst) with separate > menu configuration when own IP is known and if file is not found > switch do default one.
> So I strongly vote for a way to be able to use server IP provided > by DHCP/PXE. I vote for using the ethernet card's MAC address (which never changes) instead of whatever IP address the DHCP server felt like *dynamically* assigning... GRUB could (should?) download a configuration file from the TFTP server that's called "123456789ABC.cfg" or "123456789ABC/grub.cfg" (where "123456789ABC" is the ethernet card's MAC address) ; and if that's not found it should try something like "default.cfg". Putting the ethernet card's MAC address and the current IP address into an environment variable (e.g. for use in command line parameters) might be fun too. Note 1: the easiest way to find the ethernet card's MAC address and the computer's IP address is to use the "GET_CACHED_INFO" function (opcode 7), with the Packet type field set to 2 (DHCP ACK from server); because you need to use this function to find the IP address of the TFTP server anyway. Note 2: the name "your_ip" probably came from the PXE specification. Cheers, Brendan _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel