Adding a post script

246 views
Skip to first unread message

Matt

unread,
Mar 16, 2021, 12:46:35 AM3/16/21
to Warewulf
New to warewulf obviously, still trying to deploy an aarch64 cluster and getting close thanks to your help.  In xcat we add postscript very easily having issues with warewulf.  We need a  post script to run on  this cluster to  enroll computes into our SSSD cluster and mot likely  a lot more.

Here is what I have done but do not see ANYTHING happening on the computes.  I'd regenerated a stateful image after making these change, reprovisioned the nodes, and pxe update.  

Also is it possible to add more than one post script?  

Thanks.

 wwsh -y file import postinstall.sh  --name=postinstall.sh

 wwsh -y object modify -s format=shell postinstall.sh

 wwsh object modify -s postscript=postinstall.sh cedar-cn01

  wwsh object modify -s format=shell postinstall.sh

  wwsh -y object modify -s postscript=postinstall.sh

   wwsh  object modify -s postscript=postinstall.sh 


wwsh object print

postinstall.sh             file     


 wwsh file print postinstall.sh

#### postinstall.sh ###########################################################

postinstall.sh  : ID               = 98

postinstall.sh  : NAME             = postinstall.sh

postinstall.sh  : PATH             = /root/files/postinstall.sh

postinstall.sh  : ORIGIN           = /root/files/postinstall.sh

postinstall.sh  : FORMAT           = shell

postinstall.sh  : CHECKSUM         = 68aa62254e9985f76e30d692b3a271d0

postinstall.sh  : INTERPRETER      = UNDEF

postinstall.sh  : SIZE             = 811

postinstall.sh  : MODE             = 0755

postinstall.sh  : UID              = 0

postinstall.sh  : GID              = 0         


         #### node cedar-cn01.cedar.cluster ############################################

      25: NAME       = cedar-cn01,cedar-cn01.cedar.cluster

      25: ARCH       = aarch64

      25: BOOTLOADER = nvme0n1

      25: BOOTSTRAPID = 22

      25: DOMAIN     = cedar.cluster

      25: FILEIDS    = 11,14,15,24,71,72,73,86,87,96,97

      25: FS         = fstab p1 /boot/efi vfat defaults 0 0,fstab p2 /boot ext4 defaults 0 0,fstab p3 swap swap defaults 0 0,fstab p4 / ext4 defaults 0 0,fstab p5 /data ext4 defaults 0 0,mklabel gpt,mkpart ESP fat32 1MiB 513MiB,mkpart primary ext4 120325MiB 100%,mkpart primary ext4 17921MiB 120325MiB,mkpart primary ext4 513MiB 1557MiB,mkpart primary linux-swap 1557MiB 17921MiB,name 1 ESP,name 2 boot,name 3 swap,name 4 root,name 5 data,select /dev/nvme0n1,set 1 boot on

      25: GROUPS     = ALL,C1

      25: KARGS      = acpi=force,biosdevname=0,console=ttyAMA0,earlycon=pl011,0x1c050000,net.ifnames=0

      25: NETDEVS    = ObjectSet

            NETDEVS.eth0.NAME         = eth0

            NETDEVS.eth0.GATEWAY      = 172.21.3.254

            NETDEVS.eth0.HWADDR       = 2c:d4:44:ce:90:cd

            NETDEVS.eth0.IPADDR       = 172.21.3.101

            NETDEVS.eth0.NETMASK      = 255.255.255.0

            NETDEVS.ib0.NAME          = ib0

            NETDEVS.ib0.IPADDR        = 172.40.3.101

            NETDEVS.ib0.NETMASK       = 255.255.0.0

      25: NODENAME   = cedar-cn01

      25: POSTSCRIPT = postinstall.sh

      25: VNFSID     = 95 

Matt

unread,
Mar 16, 2021, 12:06:54 PM3/16/21
to Warewulf, Matt
Gave up on this post script, doesn't work on our system, trying to do it the xcat way.   I have an nfs share from the  warewulf deploy node and the script there trying to just execute this script via rc.local but it does not  get  executed.  Is there something in warewulf with regard to running rc.local?  it is +x and is supposed to just execute a simple script

[root@cedar-deploy centos8.2-stateful-golden]# cd etc/

[root@cedar-deploy etc]# cat rc.local

#!/bin/bash

# THIS FILE IS ADDED FOR COMPATIBILITY PURPOSES

touch /var/lock/subsys/local

/opt/ohpc/pub/postscripts/postinstall.sh



If I can't get this working I guess have to make a service  call this post script that way.


Reply all
Reply to author
Forward
0 new messages