* Changes of existing tools: dbginfo.sh: Add details on CPU-measurement dbginfo.sh: Add new crypto command dbginfo.sh: Add overview commands and crypto update dbginfo.sh: Adding kdump info dbginfo.sh: Removing outdated email references dbginfo.sh: Rework network section dbginfo.sh: Update copyright 2nd year pvimg: Add '--(enable|disable)-image-encryption' flags to 'pvimg create' pvimg: Add '--cck ' command line option and make '--comm-key' an alias pvimg: Add '--hdr-key' command line option to 'pvimg create' pvimg: Rename '--key' into '--hdr-key' and use '--key' as an alias (for 'pvimg info') pvsecret: Add support for retrievable secrets ziorep_config: Add PCHID field to adapter report ziorep_traffic: Add DEVBUSID column to traffic report ziorep_utilization: Add --fcp-device parameter to print virtual adapter report ziorep_utilization: Add PCHID column to physical adapter report ziorep_utilization: Now prints only physical adapter report by default ziorep_utilization: Swap Bus-ID and CHPID columns in virtual adapter report zipl/boot: Increase section size for eckd_mv dumper zkey: Add support for listing and importing protected virtualization secrets * Bug Fixes: chpstat: Fix invalid utilization data on older kernels opticsmon: Fix runaway loop in on_link_change() zipl: Update inline assembly for GCC 15 zipl_helper.device-mapper: Add missed step in logical device resolution - Revendored vendor.tar.gz - Removed obsolete patches: * s390-tools-01-zipl_helper.device-mapper-add-missed-step-in-logical.patch * s390-tools-02-zipl-src-fix-imprecise-check-that-file-is-on-specifi.patch * s390-tools-General-update-01.patch * s390-tools-General-update-02.patch * s390-tools-General-update-03.patch * s390-tools-General-update-04.patch * s390-tools-General-update-05.patch * s390-tools-General-update-06.patch * s390-tools-General-update-07.patch * s390-tools-General-update-08.patch * s390-tools-General-update-09.patch * s390-tools-General-update-10.patch * s390-tools-General-update-11.patch * s390-tools-General-update-12.patch * s390-tools-Additional-update-01.patch * s390-tools-Additional-update-02.patch * s390-tools-pvimg-info-command-01.patch * s390-tools-pvimg-info-command-02.patch * s390-tools-pvimg-info-command-03.patch * s390-tools-Support-unencrypted-SE-images-01.patch * s390-tools-pvimg-info-command-04.patch * s390-tools-pvimg-additional-01.patch * s390-tools-01-zkey-Add-support-for-retrieving-a-list-of-ultravisor-secrets.patch * s390-tools-02-zkey-Add-the--pvsecrets-list-command.patch * s390-tools-03-zkey-Add-PVSECRETS-AES-key-type.patch * s390-tools-04-zkey-Add-the-pvsecrets-import-command.patch * s390-tools-05-zkey-Reject-key-generation-and-APQN-association-for-PVSECRET-AES-keys.patch * s390-tools-06-zkey-Reject-re-enciphering-of-PVSECRET-AES-keys.patch * s390-tools-07-zkey-Support-validation-of-key-of-type-PVSECRET-AES.patch * s390-tools-08-rust-pvimg-Fix-flag-parsing-for-allowing-dump.patch * s390-tools-09-rust-pvimg-Document-the-change-from--comm-key-to--cck.patch OBS-URL: https://build.opensuse.org/package/show/Base:System/s390-tools?expand=0&rev=249
93 lines
2.3 KiB
Bash
93 lines
2.3 KiB
Bash
#!/bin/sh
|
|
#
|
|
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
#
|
|
# Perform setup tasks based on what hypervisor is in charge.
|
|
#
|
|
|
|
# Source the sysconfig file
|
|
if [ -r /etc/sysconfig/virtsetup ]; then
|
|
. /etc/sysconfig/virtsetup
|
|
else echo "No /etc/sysconfig/virtsetup file was found."
|
|
exit 1
|
|
fi
|
|
|
|
#
|
|
# Get our hostname
|
|
#
|
|
my_hostname="$(hostname)"
|
|
|
|
#
|
|
# Find out the hypervisor we're running on/under.
|
|
#
|
|
hypervisor="$(/usr/bin/systemd-detect-virt)"
|
|
|
|
case "${hypervisor}" in
|
|
zvm)
|
|
if [ ! -c /dev/vmcp ]; then
|
|
modprobe vmcp
|
|
sleep 1
|
|
if [ ! -c /dev/vmcp ]; then
|
|
echo "Unable to load the vmcp kernel module."
|
|
exit 1
|
|
fi
|
|
fi
|
|
echo "The vmcp device driver is ready."
|
|
if [ "${ZVM_DETACH_DISKS}" == "yes" ]; then
|
|
echo "Detaching devices to prepare for Live Guest Relocation."
|
|
/usr/lib/systemd/scripts/detach_disks.sh
|
|
fi
|
|
if [ "${ZVM_WARN_ABOUT_POSSIBLE_LGR_PROBLEMS}" == yes ]; then
|
|
/sbin/lgr_check
|
|
fi
|
|
;;
|
|
none)
|
|
hypervisor="lpar"
|
|
if [ "${LPAR_SCLP_HOSTNAME}" == "yes" ]; then
|
|
# If the sclp_cpi module is already loaded, we have to unload it
|
|
# so we can be sure it has the correct system name specified
|
|
# when we reload it again.
|
|
if grep -qw sclp_cpi /proc/modules 2>/dev/null; then
|
|
rmmod sclp_cpi
|
|
sleep 1
|
|
fi
|
|
if grep -qw sclp_cpi /proc/modules 2>/dev/null; then
|
|
echo "Unable to unload the sclp_cpi kernel module."
|
|
exit 1
|
|
fi
|
|
echo "Setting the LPAR name via the sclp_cpi module."
|
|
modprobe sclp_cpi system_name="$my_hostname"
|
|
if ! grep -qw sclp_cpi /proc/modules 2>/dev/null; then
|
|
echo "We were unable to load the sclp_cpi module to set the LPAR name."
|
|
exit 2
|
|
fi
|
|
fi
|
|
;;
|
|
kvm)
|
|
;;
|
|
*)
|
|
echo "An unknown hypervisor, \"${hypervisor}\" was detected."
|
|
echo "Please report this to your support provider."
|
|
exit 3
|
|
;;
|
|
esac
|
|
|
|
#
|
|
# Now let's check for any scripts that other packages may have provided
|
|
# to do specific things they need. The scripts must be marked executable
|
|
# and have a suffix indicating which hypervisor for which they are to be run.
|
|
# Currently that is one of: kvm, lpar, or zvm.
|
|
# E.g., 01-test.script.zvm would only be run if the system is a z/VM guest.
|
|
#
|
|
|
|
for script in $(ls /lib/s390-tools/virtsetup/*.${hypervisor} 2>/dev/null)
|
|
do if [ -x "${script}" ]; then
|
|
echo "Executing ${script}..."
|
|
"${script}"
|
|
echo "Done."
|
|
echo
|
|
fi
|
|
done
|
|
|
|
exit 0
|