From f045f67994c322286000612cb92b796724c041aa Mon Sep 17 00:00:00 2001 From: Mark Gurevich Date: Wed, 21 Apr 2021 08:46:17 -0400 Subject: [PATCH] Support Oracle Linux on service nodes --- perl-xCAT/xCAT/data/discinfo.pm | 7 ------ xCAT-server/lib/xcat/plugins/anaconda.pm | 22 +++++++++++++++++-- .../share/xcat/install/ol/service.ol7.tmpl | 1 + .../ol/service.ol7.x86_64.otherpkgs.pkglist | 1 + .../install/ol/service.ol7.x86_64.pkglist | 1 + .../share/xcat/install/ol/service.ol8.pkglist | 1 + .../ol/service.ol8.ppc64le.otherpkgs.pkglist | 1 + .../share/xcat/install/ol/service.ol8.tmpl | 1 + .../ol/service.ol8.x86_64.otherpkgs.pkglist | 1 + .../xcat/netboot/ol/service.ol7.x86_64.exlist | 1 + .../ol/service.ol7.x86_64.otherpkgs.pkglist | 1 + .../netboot/ol/service.ol7.x86_64.pkglist | 1 + .../netboot/ol/service.ol7.x86_64.postinstall | 1 + .../xcat/netboot/ol/service.ol8.x86_64.exlist | 1 + .../ol/service.ol8.x86_64.otherpkgs.pkglist | 1 + .../netboot/ol/service.ol8.x86_64.pkglist | 1 + .../netboot/ol/service.ol8.x86_64.postinstall | 1 + 17 files changed, 35 insertions(+), 9 deletions(-) create mode 120000 xCAT-server/share/xcat/install/ol/service.ol7.tmpl create mode 120000 xCAT-server/share/xcat/install/ol/service.ol7.x86_64.otherpkgs.pkglist create mode 120000 xCAT-server/share/xcat/install/ol/service.ol7.x86_64.pkglist create mode 120000 xCAT-server/share/xcat/install/ol/service.ol8.pkglist create mode 120000 xCAT-server/share/xcat/install/ol/service.ol8.ppc64le.otherpkgs.pkglist create mode 120000 xCAT-server/share/xcat/install/ol/service.ol8.tmpl create mode 120000 xCAT-server/share/xcat/install/ol/service.ol8.x86_64.otherpkgs.pkglist create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.exlist create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.otherpkgs.pkglist create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.pkglist create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.postinstall create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.exlist create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.otherpkgs.pkglist create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.pkglist create mode 120000 xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.postinstall diff --git a/perl-xCAT/xCAT/data/discinfo.pm b/perl-xCAT/xCAT/data/discinfo.pm index b406c834d..445cf5eab 100755 --- a/perl-xCAT/xCAT/data/discinfo.pm +++ b/perl-xCAT/xCAT/data/discinfo.pm @@ -136,13 +136,6 @@ our %distnames = ( "1390839789.062069" => "SL6.5", #x86_64 DVD ISO Install "1529960248.065311" => "ol6.10", # x86_64, Oracle Linux 6.10 - "1565395001.564692" => "ol7.7", # x86_64, Oracle Linux 7.7 - "1586293815.797636" => "ol7.8", # x86_64, Oracle Linux 7.8 - "1601956087.745957" => "ol7.9", # x86_64, Oracle Linux 7.9 - "1563868563.575621" => "ol8.0", # x86_64, Oracle Linux 8.0 - "1573718260.172018" => "ol8.1", # x86_64, Oracle Linux 8.1 - "1588679121.349755" => "ol8.2", # x86_64, Oracle Linux 8.2 - "1604965593.730885" => "ol8.3", # x86_64, Oracle Linux 8.3 "1394111947.452332" => "pkvm2.1", # ppc64, PowerKVM "1413749127.352649" => "pkvm2.1.1", # ppc64, PowerKVM diff --git a/xCAT-server/lib/xcat/plugins/anaconda.pm b/xCAT-server/lib/xcat/plugins/anaconda.pm index e27ee05a0..44b8413c7 100644 --- a/xCAT-server/lib/xcat/plugins/anaconda.pm +++ b/xCAT-server/lib/xcat/plugins/anaconda.pm @@ -2033,7 +2033,7 @@ sub copycd if (-r $mntpath . "/.discinfo") { - print "DEBUG - [anaconda.pm] Attempt to detemine OS information from the .discinfo file ...\n"; + print "DEBUG - [anaconda.pm] Attempt to detemine OS information from the $mntpath/.discinfo file ...\n"; open($dinfo, $mntpath . "/.discinfo"); $did = <$dinfo>; @@ -2073,7 +2073,7 @@ sub copycd $dno = $1; } } - print "DEBUG - [anaconda.pm] Distname=$distname, OS=$desc, ARCH=$arch, Version=$dno\n"; + print "DEBUG - [anaconda.pm] Distname=$distname, OS=$desc, ARCH=$darch, Version=$dno\n"; unless ($distname) { @@ -2109,6 +2109,24 @@ sub copycd } close($dinfo); } + elsif ($desc =~ /Oracle Linux/) + { + # + # Attempt to auto-detect for OL8 OS, the last element has typically been the version + # ex: "Oracle Linux 8.3.0" + # + my @ol_version = split / /, $desc; + $distname = "ol" . $ol_version[-1]; + } + elsif ($desc =~ /OL-/) + { + # + # Attempt to auto-detect for OL7 OS, the last element has typically been the version + # ex: OL-7.9 Server.x86_64 + # + my @ol_version = split /[- ]/, $desc; + $distname = "ol" . $ol_version[1]; + } elsif ($desc =~ /^[\d\.]+$/) { open($dinfo, $mntpath . "/.treeinfo"); diff --git a/xCAT-server/share/xcat/install/ol/service.ol7.tmpl b/xCAT-server/share/xcat/install/ol/service.ol7.tmpl new file mode 120000 index 000000000..453d4b94a --- /dev/null +++ b/xCAT-server/share/xcat/install/ol/service.ol7.tmpl @@ -0,0 +1 @@ +../rh/service.rhels7.tmpl \ No newline at end of file diff --git a/xCAT-server/share/xcat/install/ol/service.ol7.x86_64.otherpkgs.pkglist b/xCAT-server/share/xcat/install/ol/service.ol7.x86_64.otherpkgs.pkglist new file mode 120000 index 000000000..7166f39c2 --- /dev/null +++ b/xCAT-server/share/xcat/install/ol/service.ol7.x86_64.otherpkgs.pkglist @@ -0,0 +1 @@ +../rh/service.rhels7.x86_64.otherpkgs.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/install/ol/service.ol7.x86_64.pkglist b/xCAT-server/share/xcat/install/ol/service.ol7.x86_64.pkglist new file mode 120000 index 000000000..8836bf046 --- /dev/null +++ b/xCAT-server/share/xcat/install/ol/service.ol7.x86_64.pkglist @@ -0,0 +1 @@ +../rh/service.rhels7.x86_64.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/install/ol/service.ol8.pkglist b/xCAT-server/share/xcat/install/ol/service.ol8.pkglist new file mode 120000 index 000000000..818f670ec --- /dev/null +++ b/xCAT-server/share/xcat/install/ol/service.ol8.pkglist @@ -0,0 +1 @@ +../rh/service.rhels8.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/install/ol/service.ol8.ppc64le.otherpkgs.pkglist b/xCAT-server/share/xcat/install/ol/service.ol8.ppc64le.otherpkgs.pkglist new file mode 120000 index 000000000..ed90f050f --- /dev/null +++ b/xCAT-server/share/xcat/install/ol/service.ol8.ppc64le.otherpkgs.pkglist @@ -0,0 +1 @@ +../rh/service.rhels8.ppc64le.otherpkgs.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/install/ol/service.ol8.tmpl b/xCAT-server/share/xcat/install/ol/service.ol8.tmpl new file mode 120000 index 000000000..373e2f6eb --- /dev/null +++ b/xCAT-server/share/xcat/install/ol/service.ol8.tmpl @@ -0,0 +1 @@ +../rh/service.rhels8.tmpl \ No newline at end of file diff --git a/xCAT-server/share/xcat/install/ol/service.ol8.x86_64.otherpkgs.pkglist b/xCAT-server/share/xcat/install/ol/service.ol8.x86_64.otherpkgs.pkglist new file mode 120000 index 000000000..03999f75f --- /dev/null +++ b/xCAT-server/share/xcat/install/ol/service.ol8.x86_64.otherpkgs.pkglist @@ -0,0 +1 @@ +../rh/service.rhels8.x86_64.otherpkgs.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.exlist b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.exlist new file mode 120000 index 000000000..71786c8e0 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.exlist @@ -0,0 +1 @@ +../rh/service.rhels7.x86_64.exlist \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.otherpkgs.pkglist b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.otherpkgs.pkglist new file mode 120000 index 000000000..7166f39c2 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.otherpkgs.pkglist @@ -0,0 +1 @@ +../rh/service.rhels7.x86_64.otherpkgs.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.pkglist b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.pkglist new file mode 120000 index 000000000..8836bf046 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.pkglist @@ -0,0 +1 @@ +../rh/service.rhels7.x86_64.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.postinstall b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.postinstall new file mode 120000 index 000000000..bce5cd2cd --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol7.x86_64.postinstall @@ -0,0 +1 @@ +../rh/service.rhels7.x86_64.postinstall \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.exlist b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.exlist new file mode 120000 index 000000000..9d1e45244 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.exlist @@ -0,0 +1 @@ +../rh/service.rhels8.x86_64.exlist \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.otherpkgs.pkglist b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.otherpkgs.pkglist new file mode 120000 index 000000000..03999f75f --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.otherpkgs.pkglist @@ -0,0 +1 @@ +../rh/service.rhels8.x86_64.otherpkgs.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.pkglist b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.pkglist new file mode 120000 index 000000000..cba1edc0e --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.pkglist @@ -0,0 +1 @@ +../rh/service.rhels8.x86_64.pkglist \ No newline at end of file diff --git a/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.postinstall b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.postinstall new file mode 120000 index 000000000..cd4cbff17 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ol/service.ol8.x86_64.postinstall @@ -0,0 +1 @@ +../rh/service.rhels8.x86_64.postinstall \ No newline at end of file