From 22b16df73632af04a2ea9be667b5f1d4dc379356 Mon Sep 17 00:00:00 2001 From: mxi1 Date: Fri, 2 Apr 2010 07:11:44 +0000 Subject: [PATCH] -bug 2945115 is fixed; the checkpoint of kernel version is pushed back git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@5650 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/share/xcat/netboot/sles/genimage | 33 ++++++++++---------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/xCAT-server/share/xcat/netboot/sles/genimage b/xCAT-server/share/xcat/netboot/sles/genimage index e6cd5916c..005693161 100755 --- a/xCAT-server/share/xcat/netboot/sles/genimage +++ b/xCAT-server/share/xcat/netboot/sles/genimage @@ -179,22 +179,6 @@ if (!$destdir) $rootimg_dir="$destdir/rootimg"; -#Default to the first kernel found in the install image if nothing specified explicitly. -#A more accurate guess than whatever the image build server happens to be running -#If specified, that takes precedence. -#if image has one, that is used -#if all else fails, resort to uname -r like this script did before -my @KVERS= <$rootimg_dir/lib/modules/*>; -if (scalar(@KVERS)) { - $basekernelver = basename($KVERS[0]); -} -unless ($basekernelver) { - $basekernelver = `uname -r`; -} -unless ($kernelver) { - $kernelver=$basekernelver; -} -chomp($kernelver); unless ($osver and $profile and $netdriver and $prinic) { print 'Usage: genimage -i -n [-r ] -k -o -p -a [-m [--permission ]]'."\n"; print ' genimage -i -n [-r ] -k '."\n"; @@ -467,6 +451,23 @@ if($ret > 0) { system("umount -l $rootimg_dir/proc"); } +#Default to the first kernel found in the install image if nothing specified explicitly. +#A more accurate guess than whatever the image build server happens to be running +#If specified, that takes precedence. +#if image has one, that is used +#if all else fails, resort to uname -r like this script did before +my @KVERS= <$rootimg_dir/lib/modules/*>; +if (scalar(@KVERS)) { + $basekernelver = basename($KVERS[0]); +} +unless ($basekernelver) { + $basekernelver = `uname -r`; +} +unless ($kernelver) { + $kernelver=$basekernelver; +} +chomp($kernelver); + mkinitrd();