diff --git a/kickstart/files/kickstart.cfg b/kickstart/files/kickstart.cfg index a7b954ed..a57d7c65 100644 --- a/kickstart/files/kickstart.cfg +++ b/kickstart/files/kickstart.cfg @@ -2787,14 +2787,28 @@ if [ "${controller}" = true ] ; then ilog "Temporary backup mount is ${backup_mount}" mkdir -p "${backup_mount}" - mount "${backup_device}" "${backup_mount}" 2>/dev/null + mount "${backup_device}" "${backup_mount}" + rc=$? + if [ ${rc} -ne 0 ]; then + report_failure_with_msg "Unable to mount ${backup_device} on ${backup_mount} [rc=${rc}]" + fi ilog "Copying repo to ${backup_mount}" cp -a ${repo} ${backup_mount} rc=$? if [ ${rc} -ne 0 ]; then - report_failure_with_msg "Unable to copy repo to /opt/platform-backup" + report_failure_with_msg "Unable to copy repo to /opt/platform-backup [rc=${rc}]" fi + + if [ -e "/instboot/opt/platform-backup/${sw_release}" ]; then + ilog "Copying images and patches to ${backup_mount}" + cp -a /instboot/opt/platform-backup/${sw_release} ${backup_mount} + rc=$? + if [ ${rc} -ne 0 ]; then + report_failure_with_msg "Unable to copy images from /instboot to /opt/platform-backup [rc=${rc}]" + fi + fi + umount "${backup_mount}" fi else