add kdump support for redhat7 stateless
This commit is contained in:
parent
a6ca187a16
commit
4e9ee2bbdc
@ -246,6 +246,13 @@ sub process_request {
|
||||
}
|
||||
}
|
||||
|
||||
#restore the install.netboot of xcat dracut module
|
||||
if(-e "$rootimg_dir/usr/lib/dracut/modules.d/97xcat/install"){
|
||||
xCAT::Utils->runcmd("mv $rootimg_dir/usr/lib/dracut/modules.d/97xcat/install $rootimg_dir/.statebackup/install", 0, 1);
|
||||
}
|
||||
xCAT::Utils->runcmd("cp /opt/xcat/share/xcat/netboot/rh/dracut_033/install.netboot $rootimg_dir/usr/lib/dracut/modules.d/97xcat/install", 0, 1);
|
||||
|
||||
|
||||
my $xcat_packimg_tmpfile = "/tmp/xcat_packimg.$$";
|
||||
my $excludestr = "find . -xdev ";
|
||||
my $includestr;
|
||||
@ -439,6 +446,8 @@ sub process_request {
|
||||
xCAT::Utils->runcmd("mv $rootimg_dir/.statebackup$filename $rootimg_dir$filename", 0, 1);
|
||||
}
|
||||
}
|
||||
|
||||
xCAT::Utils->runcmd("mv $rootimg_dir/.statebackup/install $rootimg_dir/usr/lib/dracut/modules.d/97xcat/install", 0, 1);
|
||||
xCAT::Utils->runcmd("mv $rootimg_dir/.statebackup/statelite $rootimg_dir/etc/init.d/statelite", 0, 1);
|
||||
xCAT::Utils->runcmd("rm -rf $rootimg_dir/.statebackup", 0, 1);
|
||||
}
|
||||
|
@ -218,8 +218,10 @@ EOF
|
||||
[ -d $MOUNTPATH/var/crash ] || mkdir -p $MOUNTPATH/var/crash
|
||||
echo "nfs $KDIP:$KDPATH" > /etc/kdump.conf
|
||||
echo "default shell" >> /etc/kdump.conf
|
||||
sed -i 's/KDUMP_COMMANDLINE_APPEND="/KDUMP_COMMANDLINE_APPEND="nonodestatus /' /etc/sysconfig/kdump
|
||||
sed -i 's/KDUMP_COMMANDLINE_APPEND="/KDUMP_COMMANDLINE_APPEND="nonodestatus /' /etc/sysconfig/kdump
|
||||
[ -f /etc/dracut.conf ] && mv /etc/dracut.conf /tmp/dracut.conf
|
||||
restartservice kdump
|
||||
[ -f /tmp/dracut.conf ] && mv /tmp/dracut.conf /etc/dracut.conf
|
||||
elif (pmatch $OSVER "fedora*") || (pmatch $OSVER "rhel6*") || (pmatch $OSVER "rhels6*") || [ -f /etc/fedora-release ] || [ -f /etc/redhat-release ];then
|
||||
/bin/mount -o nolock $KDIP:$KDPATH $MOUNTPATH
|
||||
echo "net $KDIP:$KDPATH" > /etc/kdump.conf
|
||||
|
Loading…
Reference in New Issue
Block a user