mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-06-18 12:20:40 +00:00
1, add default pkglist/otherpkglist/exlixt/postinstall for rhels7 ppc64le/x86_64 stateless service node (#3859)
2, restart xcat when run 'servicenode'
This commit is contained in:
@ -0,0 +1,35 @@
|
||||
./boot*
|
||||
./usr/share/wallpapers/RHEL6/contents/images*
|
||||
./usr/include*
|
||||
./usr/lib/locale*
|
||||
./usr/lib64/perl5/Encode/CN*
|
||||
./usr/lib64/perl5/Encode/JP*
|
||||
./usr/lib64/perl5/Encode/TW*
|
||||
./usr/lib64/perl5/Encode/KR*
|
||||
./lib/kbd/keymaps/i386*
|
||||
./lib/kbd/keymaps/mac*
|
||||
./lib/kdb/keymaps/include*
|
||||
./usr/local/include*
|
||||
./usr/local/share/man*
|
||||
./usr/share/man*
|
||||
./usr/share/cracklib*
|
||||
./usr/share/doc*
|
||||
./usr/share/doc/packages/cyrus-sasl/doc*
|
||||
./usr/share/gnome*
|
||||
./usr/share/i18n*
|
||||
+./usr/share/i18n/en_US*
|
||||
./usr/share/info*
|
||||
./usr/share/locale/*
|
||||
+./usr/share/locale/en_US*
|
||||
+./usr/share/locale/C*
|
||||
+./usr/share/locale/locale.alias
|
||||
+./usr/lib/locale/locale-archive
|
||||
+./usr/lib/locale/en*
|
||||
./usr/share/man*
|
||||
./usr/share/omf*
|
||||
./usr/share/vim/site/doc*
|
||||
./usr/share/vim/vim74/doc*
|
||||
./usr/share/zoneinfo*
|
||||
./var/cache/man*
|
||||
./var/lib/yum*
|
||||
./tmp*
|
@ -0,0 +1,4 @@
|
||||
xcat/xcat-core/xCATsn
|
||||
xcat/xcat-dep/rh7/ppc64le/conserver-xcat
|
||||
xcat/xcat-dep/rh7/ppc64le/perl-Net-Telnet
|
||||
xcat/xcat-dep/rh7/ppc64le/perl-Expect
|
@ -0,0 +1,47 @@
|
||||
bash
|
||||
bc
|
||||
bind
|
||||
bind-utils
|
||||
busybox
|
||||
bzip2
|
||||
cronie
|
||||
dhclient
|
||||
dhcp
|
||||
dracut
|
||||
dracut-network
|
||||
e2fsprogs
|
||||
expect
|
||||
gzip
|
||||
httpd
|
||||
iputils
|
||||
irqbalance
|
||||
kernel
|
||||
ksh
|
||||
lsvpd
|
||||
mysql-connector-odbc
|
||||
net-snmp-perl
|
||||
nfs-utils
|
||||
ntp
|
||||
openssh-clients
|
||||
openssh-server
|
||||
openssl
|
||||
parted
|
||||
perl-DBD-MySQL
|
||||
perl-DBD-Pg
|
||||
perl-IO-Socket-SSL
|
||||
perl-Net-Telnet
|
||||
perl-XML-Parser
|
||||
perl-XML-Simple
|
||||
postgresql
|
||||
postgresql-server
|
||||
ppc64-utils
|
||||
procps
|
||||
rootfiles
|
||||
rpm
|
||||
rsync
|
||||
tar
|
||||
unixODBC
|
||||
vim-minimal
|
||||
vsftpd
|
||||
wget
|
||||
xz
|
45
xCAT-server/share/xcat/netboot/rh/service.rhels7.ppc64le.postinstall
Executable file
45
xCAT-server/share/xcat/netboot/rh/service.rhels7.ppc64le.postinstall
Executable file
@ -0,0 +1,45 @@
|
||||
#!/bin/sh
|
||||
#-- Do not remove following line if you want to make use of CVS version tracking
|
||||
#-- $Id: service.postinstall,v 1.21 2008/09/04 12:05:45 sikorsky Exp $
|
||||
#-- jurij.sikorsky@t-systems.cz
|
||||
#--
|
||||
#-- this script is run after all packages from $profile.pkglist are installed
|
||||
#--
|
||||
#-- it gets these arguments:
|
||||
#--
|
||||
#-- $1 = install root (chroot directory for profile)
|
||||
#-- $2 = OS version
|
||||
#-- $3 = architecture
|
||||
#-- $4 = profile name
|
||||
#-- $5 = work dir (where genimage is located)
|
||||
#--
|
||||
#--
|
||||
installroot=$1
|
||||
osver=$2
|
||||
arch=$3
|
||||
profile=$4
|
||||
workdir=$5
|
||||
|
||||
#-- Example how /etc/fstab can be automatically generated during image generation:
|
||||
#cat <<END >$installroot/etc/fstab
|
||||
#proc /proc proc rw 0 0
|
||||
#sysfs /sys sysfs rw 0 0
|
||||
#devpts /dev/pts devpts rw,gid=5,mode=620 0 0
|
||||
#${profile}_${arch} / tmpfs rw 0 1
|
||||
#none /tmp tmpfs defaults,size=10m 0 2
|
||||
#none /var/tmp tmpfs defaults,size=10m 0 2
|
||||
#END
|
||||
|
||||
#-- Uncomment the line contains "cons" in /etc/inittab
|
||||
#cons:12345:respawn:/sbin/smart_agetty -L 38400 console
|
||||
echo "co:2345:respawn:/sbin/agetty -L 38400 console" >> $installroot/etc/inittab
|
||||
|
||||
|
||||
#-- Example of booted image versioning
|
||||
#-- We want to know, with what configuration (version of the image) each node was booted.
|
||||
#-- Hence, we keep image definition files and postscripts in CVS. During image generation we create file /etc/IMGVERSION and fill it with CVS "$Id$" of files with image definition (.pkglist, .exlist, .repolist, .postinstall). Then, during boot, each "CVS enabled" postscript (see /install/postscripts/cvs_template.sh and /install/postscripts/cvs_template.pl) adds one line to /etc/IMGVERSION. Then you can determine in any time what image you are running and what postscipts in which versions were run.
|
||||
#cat /dev/null > $installroot/etc/IMGVERSION
|
||||
#for ext in pkglist exlist postinstall repolist; do
|
||||
# [ -r $workdir/$profile.$ext ] && cat $workdir/$profile.$ext | grep -E '^[[:space:]]*#.*[[:space:]]\$Id' >> $installroot/etc/IMGVERSION
|
||||
#done
|
||||
|
@ -0,0 +1,35 @@
|
||||
./boot*
|
||||
./usr/share/wallpapers/RHEL6/contents/images*
|
||||
./usr/include*
|
||||
./usr/lib/locale*
|
||||
./usr/lib64/perl5/Encode/CN*
|
||||
./usr/lib64/perl5/Encode/JP*
|
||||
./usr/lib64/perl5/Encode/TW*
|
||||
./usr/lib64/perl5/Encode/KR*
|
||||
./lib/kbd/keymaps/i386*
|
||||
./lib/kbd/keymaps/mac*
|
||||
./lib/kdb/keymaps/include*
|
||||
./usr/local/include*
|
||||
./usr/local/share/man*
|
||||
./usr/share/man*
|
||||
./usr/share/cracklib*
|
||||
./usr/share/doc*
|
||||
./usr/share/doc/packages/cyrus-sasl/doc*
|
||||
./usr/share/gnome*
|
||||
./usr/share/i18n*
|
||||
+./usr/share/i18n/en_US*
|
||||
./usr/share/info*
|
||||
./usr/share/locale/*
|
||||
+./usr/share/locale/en_US*
|
||||
+./usr/share/locale/C*
|
||||
+./usr/share/locale/locale.alias
|
||||
+./usr/lib/locale/locale-archive
|
||||
+./usr/lib/locale/en*
|
||||
./usr/share/man*
|
||||
./usr/share/omf*
|
||||
./usr/share/vim/site/doc*
|
||||
./usr/share/vim/vim74/doc*
|
||||
./usr/share/zoneinfo*
|
||||
./var/cache/man*
|
||||
./var/lib/yum*
|
||||
./tmp*
|
@ -0,0 +1,4 @@
|
||||
xcat/xcat-core/xCATsn
|
||||
xcat/xcat-dep/rh7/x86_64/conserver-xcat
|
||||
xcat/xcat-dep/rh7/x86_64/perl-Net-Telnet
|
||||
xcat/xcat-dep/rh7/x86_64/perl-Expect
|
@ -0,0 +1,46 @@
|
||||
bash
|
||||
bc
|
||||
bind
|
||||
bind-utils
|
||||
busybox
|
||||
bzip2
|
||||
cronie
|
||||
dhclient
|
||||
dhcp
|
||||
dracut
|
||||
dracut-network
|
||||
e2fsprogs
|
||||
expect
|
||||
gzip
|
||||
httpd
|
||||
iputils
|
||||
irqbalance
|
||||
kernel
|
||||
ksh
|
||||
lsvpd
|
||||
mysql-connector-odbc
|
||||
net-snmp-perl
|
||||
nfs-utils
|
||||
ntp
|
||||
openssh-clients
|
||||
openssh-server
|
||||
openssl
|
||||
parted
|
||||
perl-DBD-MySQL
|
||||
perl-DBD-Pg
|
||||
perl-IO-Socket-SSL
|
||||
perl-Net-Telnet
|
||||
perl-XML-Parser
|
||||
perl-XML-Simple
|
||||
postgresql
|
||||
postgresql-server
|
||||
procps
|
||||
rootfiles
|
||||
rpm
|
||||
rsync
|
||||
tar
|
||||
unixODBC
|
||||
vim-minimal
|
||||
vsftpd
|
||||
wget
|
||||
xz
|
45
xCAT-server/share/xcat/netboot/rh/service.rhels7.x86_64.postinstall
Executable file
45
xCAT-server/share/xcat/netboot/rh/service.rhels7.x86_64.postinstall
Executable file
@ -0,0 +1,45 @@
|
||||
#!/bin/sh
|
||||
#-- Do not remove following line if you want to make use of CVS version tracking
|
||||
#-- $Id: service.postinstall,v 1.21 2008/09/04 12:05:45 sikorsky Exp $
|
||||
#-- jurij.sikorsky@t-systems.cz
|
||||
#--
|
||||
#-- this script is run after all packages from $profile.pkglist are installed
|
||||
#--
|
||||
#-- it gets these arguments:
|
||||
#--
|
||||
#-- $1 = install root (chroot directory for profile)
|
||||
#-- $2 = OS version
|
||||
#-- $3 = architecture
|
||||
#-- $4 = profile name
|
||||
#-- $5 = work dir (where genimage is located)
|
||||
#--
|
||||
#--
|
||||
installroot=$1
|
||||
osver=$2
|
||||
arch=$3
|
||||
profile=$4
|
||||
workdir=$5
|
||||
|
||||
#-- Example how /etc/fstab can be automatically generated during image generation:
|
||||
#cat <<END >$installroot/etc/fstab
|
||||
#proc /proc proc rw 0 0
|
||||
#sysfs /sys sysfs rw 0 0
|
||||
#devpts /dev/pts devpts rw,gid=5,mode=620 0 0
|
||||
#${profile}_${arch} / tmpfs rw 0 1
|
||||
#none /tmp tmpfs defaults,size=10m 0 2
|
||||
#none /var/tmp tmpfs defaults,size=10m 0 2
|
||||
#END
|
||||
|
||||
#-- Uncomment the line contains "cons" in /etc/inittab
|
||||
#cons:12345:respawn:/sbin/smart_agetty -L 38400 console
|
||||
echo "co:2345:respawn:/sbin/agetty -L 38400 console" >> $installroot/etc/inittab
|
||||
|
||||
|
||||
#-- Example of booted image versioning
|
||||
#-- We want to know, with what configuration (version of the image) each node was booted.
|
||||
#-- Hence, we keep image definition files and postscripts in CVS. During image generation we create file /etc/IMGVERSION and fill it with CVS "$Id$" of files with image definition (.pkglist, .exlist, .repolist, .postinstall). Then, during boot, each "CVS enabled" postscript (see /install/postscripts/cvs_template.sh and /install/postscripts/cvs_template.pl) adds one line to /etc/IMGVERSION. Then you can determine in any time what image you are running and what postscipts in which versions were run.
|
||||
#cat /dev/null > $installroot/etc/IMGVERSION
|
||||
#for ext in pkglist exlist postinstall repolist; do
|
||||
# [ -r $workdir/$profile.$ext ] && cat $workdir/$profile.$ext | grep -E '^[[:space:]]*#.*[[:space:]]\$Id' >> $installroot/etc/IMGVERSION
|
||||
#done
|
||||
|
@ -104,9 +104,9 @@ if ($ENV{UPDATESECURITY} && $ENV{UPDATESECURITY} eq "1") {
|
||||
&getcreds;
|
||||
} else { # Linux
|
||||
# call xcatserver,xcatclient to transfer the SSL credentials and cfgloc
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running xcatserver -d`;
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running xcatserver -d`;
|
||||
&runcmd("xcatserver -d");
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running xcatclient -d`;
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running xcatclient -d`;
|
||||
&runcmd("xcatclient -d");
|
||||
}
|
||||
|
||||
@ -137,13 +137,18 @@ else
|
||||
|
||||
©certs;
|
||||
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running xcatserver -d`;
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running 'xcatserver -d'`;
|
||||
&runcmd("xcatserver -d");
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running xcatclient -d`;
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: running 'xcatclient -d'`;
|
||||
&runcmd("xcatclient -d");
|
||||
# start xcatd if it is not up
|
||||
$rc = &runcmd("$::XCATROOT/bin/lsxcatd -v 2>/dev/null|| service xcatd restart");
|
||||
if ($rc != 0) {
|
||||
$msg = "$::sdate servicenode: Could not start xcatd.\n\n $::outref \n";
|
||||
`logger -t xcat -p local4.warning $msg`;
|
||||
}
|
||||
}
|
||||
|
||||
`logger -t xcat -p local4.info $::sdate servicenode: rc=$rc`;
|
||||
exit $rc;
|
||||
|
||||
#
|
||||
|
Reference in New Issue
Block a user