mirror of
				https://github.com/xcat2/xcat-core.git
				synced 2025-10-31 11:22:27 +00:00 
			
		
		
		
	Make makedhcp working on RHEL 8 xCAT management node (#5930)
				
					
				
			* Patch dhcp.pm for RHEL 8 * Ignore interface lo while makenetworks * Revise the comments to reflect the code changes
This commit is contained in:
		| @@ -1757,7 +1757,7 @@ sub process_request | ||||
|                 my $os_ver = $os; | ||||
|                 $os_ver =~ s/[^0-9.^0-9]//g; | ||||
|                 if (($os =~ /sles/i && $os_ver >= 11) || | ||||
|                     ($os =~ /rhels/i && $os_ver >= 7)) { | ||||
|                     ($os =~ /rhels?/i && $os_ver >= 7)) { | ||||
|  | ||||
|                     $dhcpd_key = "DHCPD_INTERFACE"; | ||||
|                     if ($usingipv6 and $dhcpver eq "dhcpd6") { | ||||
| @@ -1825,7 +1825,10 @@ sub process_request | ||||
|         if ($usingipv6) { | ||||
|  | ||||
|             # sles11.3 and rhels7 has dhcpd and dhcpd6 config in the dhcp file | ||||
|             if ($os =~ /sles/i || $os =~ /rhels7/i) { | ||||
|             my $os_ver = $os; | ||||
|             $os_ver =~ s/[^0-9.^0-9]//g; | ||||
|             if (($os =~ /sles/i && $os_ver >= 11) || | ||||
|                 ($os =~ /rhels?/i && $os_ver >= 7)) { | ||||
|                 if ($missingfiles{dhcpd}) { | ||||
|                     $callback->({ error => ["The file /etc/sysconfig/dhcpd doesn't exist, check the dhcp server"] }); | ||||
|                 } | ||||
|   | ||||
| @@ -391,9 +391,11 @@ sub donets | ||||
|         foreach (@ip6table) | ||||
|         { | ||||
|             my @ent = split /\s+/, $_; | ||||
|             if ($ent[0] eq 'fe80::/64' or $ent[0] eq 'unreachable' or $ent[1] eq 'via') { | ||||
|             if ($ent[0] eq 'fe80::/64' or $ent[0] eq 'unreachable' or | ||||
|                 $ent[1] eq 'via' or $ent[2] eq 'lo') { | ||||
|  | ||||
|                 #Do not contemplate link-local, unreachable, or gatewayed networks further | ||||
|                 #Do not contemplate link-local, unreachable, gatewayed networks, | ||||
|                 #  or networks connected to loopback interface | ||||
|                 #DHCPv6 relay will be manually entered into networks as was the case for IPv4 | ||||
|                 next; | ||||
|             } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user