aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJybz <j.biernacki@free.fr>2020-08-15 23:23:39 +0200
committerJybz <j.biernacki@free.fr>2020-08-15 23:23:39 +0200
commitc5976bf6d3c0f8d82442a163ae9cd6e0f55f446f (patch)
tree4328eb2bef0aa83efe91a78d5fb0623d3b6d583e
parentec27fd44a2e3ee0b528042cc85e0b2b4e24f037f (diff)
downloadmageia4arm-c5976bf6d3c0f8d82442a163ae9cd6e0f55f446f.tar
mageia4arm-c5976bf6d3c0f8d82442a163ae9cd6e0f55f446f.tar.gz
mageia4arm-c5976bf6d3c0f8d82442a163ae9cd6e0f55f446f.tar.bz2
mageia4arm-c5976bf6d3c0f8d82442a163ae9cd6e0f55f446f.tar.xz
mageia4arm-c5976bf6d3c0f8d82442a163ae9cd6e0f55f446f.zip
add unmount in clean
in case script crash in chroot, cleaning is not possible without unmounting.
-rwxr-xr-xcreate_arm_image.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/create_arm_image.sh b/create_arm_image.sh
index 9a9690c..d28076a 100755
--- a/create_arm_image.sh
+++ b/create_arm_image.sh
@@ -580,6 +580,7 @@ function copyingsystem()
sync
warning "You can now burn the image ( ${INSTALL_PATH}/${IMAGE} ) on SD card"
+ info "pv \"${INSTALL_PATH}/${IMAGE}\" | dd of=/dev/mmcblk#"
return 0
}
@@ -714,6 +715,11 @@ function mkfstab()
function clean()
{
title "Cleaning"
+
+ info "In case script failed or crash inside the chroot, need to unmount dev|sys|proc..."
+ /bin/umount -lf "${BUILD_PATH}/dev"
+ /bin/umount -lf "${BUILD_PATH}/sys"
+ /bin/umount -lf "${BUILD_PATH}/proc"
unmountingPartitions
unloopingImage