mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-11-28 21:32:20 +00:00
251822deae
An unknown client on an IPv6 provisioning network gets no network boot script. mknb builds its list of networks from my_nets and my_hexnets, and both skip inet6 on Linux, so nothing is written under xcat/ipxe/nets and the client has nothing to fetch. Where an address does reach a script it is written as "xcatd=" . $address . ":$port". For 2001:db8:177::1 that is xcatd=2001:db8:177::1:3001, which parses as an IPv6 literal with no port, so Genesis contacts a different address and reports nothing. The same concatenation builds the POWER HTTP URLs and the grub2 roots. xnba.pm and destiny.pm already bracket an IPv6 address through NetworkUtils::xcatd_cmdline_address and format_uri_host, so the node files were correct and the net files were not. NetworkUtils gains my_nets6, which returns the host's global IPv6 networks keyed the way my_nets keys its IPv4 ones, and ipv6_network_address, which masks an address to its prefix. my_nets keeps its IPv4-only behaviour: lsslp.pm and PPCdb.pm read its keys with dotted-quad arithmetic, so an IPv6 key there would be a wrong answer rather than a new one. my_hexnets keeps its own, because a hexnet is a PXELINUX file name built from a hexadecimal IPv4 prefix and DHCPv6 has no equivalent. mknb merges my_nets6 into the networks it writes nets/ scripts for, asks getipaddr for the IPv6 addresses of site.master as well, and takes every xcatd= value and every HTTP authority from the two formatting helpers. mknb_xcatd_address.t and networkutils_my_nets6.t fail without this change. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>