Skip to content

Test Design of xcat inventory osimage environment variables

tingtli edited this page Jun 14, 2018 · 3 revisions

Introduction

This document provides an overview of test environment variables in osimage definition files. This test plan is intended for the use of xCAT FVT team.

The test is against xCAT version 2.14.2. The build of xCAT will be picked up from the xcat.org

The xcat inventory osimage design is under https://github.com/xcat2/xcat-inventory/pull/45

Affected attributes

The follow attributes in xcat osimage inventory file might include other files by #INCLUDE:xxxxx# :

package_selection. pkglist
package_selection. otherpkglist
filestosync
genimgoptions.postinstall

According to the attributes in osimage inventory file. The attributes in osimage definition could be tested

   pkglist
   otherpkglist
   synclists   
   postinstall

Test steps

  1. create a yaml file
cat test.osimage.yaml
osimage:
  test.osimage:
    basic_attributes:
      arch: ppc64le
      distribution: rhels7.5
      osdistro: rhels7.5-ppc64le
      osname: Linux
    filestosync: {{GITREPO}}/synclist
    deprecated:
      comments: rhels7.5,ist,cida-396.27,mofed-3-2.2.2.5
    genimgoptions:
      permission: '755'
      postinstall: {{GITREPO}}/postinstall/test1.postinstall,{{GITREPO}}/postinstall/test2.postinstall
      rootimgdir: /install/custom/test.osimage
    imagetype: linux
    package_selection:
      otherpkgdir: {{SWDIR}}/otherpkgdir/
      otherpkglist: {{GITREPO}}/otherpkglist/test1.otherpkglist,{{GITREPO}}/otherpkglist/test2.otherpkglist,
      pkgdir: {{SWDIR}}/pkgdir/
      pkglist: {{GITREPO}}/pkglist/test1.pkglist,{{GITREPO}}/pkglist/test2.pkglist
    provision_mode: netboot
    role: compute
schema_version: '1.0'
  1. under /opt/xcat/share/xcat/tools/autotest/testcase/xcat-inventory/templates/, create a directory to hold all the files for GITREPO and SWDIR
environment/:
total 8
drwxr-xr-x 6 root root 4096 Jun 12 03:31 gitrepo/
drwxr-xr-x 4 root root 4096 Jun 12 03:39 swdir/

environment/gitrepo:
total 16
drwxr-xr-x 2 root root 4096 Jun 12 03:31 otherpkglist/
drwxr-xr-x 2 root root 4096 Jun 12 03:32 pkglist/
drwxr-xr-x 2 root root 4096 Jun 12 03:29 postinstall/
drwxr-xr-x 2 root root 4096 Jun 12 03:30 syncfiles/

environment/gitrepo/otherpkglist:
total 0
-rw-r--r-- 1 root root 0 Jun 12 03:31 test1.otherpkglist
-rw-r--r-- 1 root root 0 Jun 12 03:30 test2.otherpkglist

environment/gitrepo/pkglist:
total 0
-rw-r--r-- 1 root root 0 Jun 12 03:32 test1.pkglist
-rw-r--r-- 1 root root 0 Jun 12 03:32 test2.pkglist

environment/gitrepo/postinstall:
total 0
-rw-r--r-- 1 root root 0 Jun 12 03:29 test1.postinstall
-rw-r--r-- 1 root root 0 Jun 12 03:29 test2.postinstall

environment/gitrepo/syncfiles:
total 0
-rw-r--r-- 1 root root 0 Jun 12 03:13 synclist

environment/swdir:
total 8
drwxr-xr-x 2 root root 4096 Jun 12 03:39 otherpkgdir/
drwxr-xr-x 2 root root 4096 Jun 12 03:39 pkgdir/

environment/swdir/otherpkgdir:
total 0

environment/swdir/pkgdir:
total 0

  1. create correct files for synclist, otherpkglist, pkglist and postinstall

  2. Place the packages under correct directory under ohterpkgdir, pkgdir

  3. export environment variables.

[root@c910f03c05k21 rhels]# export GITREPO="/opt/xcat/share/xcat/tools/autotest/testcase/xcat-inventory/templates/environment/gitrepo"
[root@c910f03c05k21 rhels]# export SWDIR="/opt/xcat/share/xcat/tools/autotest/testcase/xcat-inventory/templates/environment/swdir"
  1. run xcat-inventory command
 xcat-inventory import -f test.osimage.yaml
  1. run provision against the imported osimage

  2. Check if the provision succeeded.

  3. Check if all the packages are installed and postinstall script is run.

News

History

  • Oct 22, 2010: xCAT 2.5 released.
  • Apr 30, 2010: xCAT 2.4 is released.
  • Oct 31, 2009: xCAT 2.3 released. xCAT's 10 year anniversary!
  • Apr 16, 2009: xCAT 2.2 released.
  • Oct 31, 2008: xCAT 2.1 released.
  • Sep 12, 2008: Support for xCAT 2 can now be purchased!
  • June 9, 2008: xCAT breaths life into (at the time) the fastest supercomputer on the planet
  • May 30, 2008: xCAT 2.0 for Linux officially released!
  • Oct 31, 2007: IBM open sources xCAT 2.0 to allow collaboration among all of the xCAT users.
  • Oct 31, 1999: xCAT 1.0 is born!
    xCAT started out as a project in IBM developed by Egan Ford. It was quickly adopted by customers and IBM manufacturing sites to rapidly deploy clusters.
Clone this wiki locally