From b375d3268cd0931e01238ffd66f4e5b29cc2de00 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Wed, 7 Aug 2019 13:17:56 -0400 Subject: [PATCH] Skip elilo for genesis in mknb mknb does not need to use elilo for genesis --- xCAT-server/lib/xcat/plugins/mknb.pm | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/xCAT-server/lib/xcat/plugins/mknb.pm b/xCAT-server/lib/xcat/plugins/mknb.pm index 1fd1d5a41..5242c9d18 100644 --- a/xCAT-server/lib/xcat/plugins/mknb.pm +++ b/xCAT-server/lib/xcat/plugins/mknb.pm @@ -48,7 +48,7 @@ sub process_request { my $httpport=""; my @hports=xCAT::TableUtils->get_site_attribute("httpport"); - if ($hports[0]){ + if ($hports[0] and $hports[0] ne "80"){ $httpport=":" . $hports[0]; } @@ -342,8 +342,14 @@ sub process_request { print $cfg " append=\"quiet xcatd=" . $normnets->{$_} . ":$xcatdport destiny=discover $consolecmdline BOOTIF=%B\"\n"; close($cfg); open($cfg, ">", "$tftpdir/xcat/xnba/nets/$net.uefi"); - print $cfg "#!gpxe\n"; - print $cfg 'chain http://${next-server}'.$httpport.'/tftpboot/xcat/elilo-x64.efi -C /tftpboot/xcat/xnba/nets/' . "$net.elilo\n"; + print $cfg 'imgfetch -n kernel http://${next-server}'.$httpport.'/tftpboot/xcat/genesis.kernel.' . "$arch quiet xcatd=" . $normnets->{$_} . ":$xcatdport $consolecmdline initrd=nbfs BOOTIF=01-" . '${netX/machyp}' . "\n"; + if ($lzma_exit_value) { + print $cfg 'imgfetch -n nbfs http://${next-server}'.$httpport.'/tftpboot/xcat/genesis.fs.' . "$arch.gz\n"; + } else { + print $cfg 'imgfetch -n nbfs http://${next-server}'.$httpport.'/tftpboot/xcat/genesis.fs.' . "$arch.lzma\n"; + } + print $cfg "imgload kernel\n"; + print $cfg "imgexec kernel\n"; close($cfg); } } elsif ($arch =~ /ppc/) {